主题是 Light+/Dark+,C/C++ Extension Pack 也装了
1
v2mm 2022-04-28 10:44:47 +08:00
试试 one dark pro
|
3
kkocdko 2022-04-28 11:24:37 +08:00 1
给出你的具体写法。我这边一切正常。Clangd 。
|
4
tengyufei 2022-04-28 11:58:17 +08:00 via Android 1
好像还是得 clangd ?
|
6
binaryify 2022-04-28 15:14:58 +08:00
可以提供下最小示例代码吗
|
7
ch2 OP @binaryify #6
#include <mysql/mysql.h> #include <iostream> #include <fstream> #include <map> using namespace std; int main(int argc, char *argv[]) { MYSQL mysql; mysql_init(&mysql); if (mysql_real_connect(&mysql, "0.0.0.0", "root", "88888888", "sys", 3306, NULL, 0) == NULL) { cout << "mysql_real_connect failed(" << mysql_error(&mysql) << ")" << endl; return -1; } mysql_set_character_set(&mysql, "utf-8"); MYSQL_RES *res; MYSQL_ROW row; int ret = mysql_query(&mysql, "select * from sys_config;"); res = mysql_store_result(&mysql); cout << "variable " << "value " << "set_time " << endl; while (row = mysql_fetch_row(res)) { cout << row[0] << " "; cout << row[1] << " "; cout << row[2] << " "; cout << endl; } mysql_free_result(res); mysql_close(&mysql); return 0; } |