Skip to content

Commit

Permalink
llcppsigfetch:set underlying panic test case in goplus#61
Browse files Browse the repository at this point in the history
  • Loading branch information
luoliwoshang committed Dec 24, 2024
1 parent 2e5f253 commit 0e93a4f
Show file tree
Hide file tree
Showing 4 changed files with 122 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
typedef gnutls_cipher_algorithm_t gnutls_cipher_algorithm;
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
typedef enum gnutls_cipher_algorithm {
GNUTLS_CIPHER_UNKNOWN = 0,
GNUTLS_CIPHER_NULL = 1,
} gnutls_cipher_algorithm_t;

#include <compact.h>
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package main

import (
test "github.com/goplus/llcppg/_xtool/llcppsigfetch/parse/cvt_test"
"github.com/goplus/llcppg/_xtool/llcppsymg/clangutils"
)

func main() {
TestInclude()
}

func TestInclude() {
test.RunTestWithConfig(&clangutils.Config{
File: "./hfile/temp.h",
Temp: false,
IsCpp: false,
})
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
#stdout
{
"./hfile/temp.h": {
"_Type": "File",
"decls": [{
"_Type": "EnumTypeDecl",
"Loc": {
"_Type": "Location",
"File": "./hfile/temp.h"
},
"Doc": null,
"Parent": null,
"Name": {
"_Type": "Ident",
"Name": "gnutls_cipher_algorithm"
},
"Type": {
"_Type": "EnumType",
"Items": [{
"_Type": "EnumItem",
"Name": {
"_Type": "Ident",
"Name": "GNUTLS_CIPHER_UNKNOWN"
},
"Value": {
"_Type": "BasicLit",
"Kind": 0,
"Value": "0"
}
}, {
"_Type": "EnumItem",
"Name": {
"_Type": "Ident",
"Name": "GNUTLS_CIPHER_NULL"
},
"Value": {
"_Type": "BasicLit",
"Kind": 0,
"Value": "1"
}
}]
}
}, {
"_Type": "TypedefDecl",
"Loc": {
"_Type": "Location",
"File": "./hfile/temp.h"
},
"Doc": null,
"Parent": null,
"Name": {
"_Type": "Ident",
"Name": "gnutls_cipher_algorithm_t"
},
"Type": {
"_Type": "TagExpr",
"Name": {
"_Type": "Ident",
"Name": "gnutls_cipher_algorithm"
},
"Tag": 2
}
}],
"includes": [{
"_Type": "Include",
"Path": "./hfile/compact.h"
}],
"macros": []
},
"./hfile/compact.h": {
"_Type": "File",
"decls": [{
"_Type": "TypedefDecl",
"Loc": {
"_Type": "Location",
"File": "./hfile/compact.h"
},
"Doc": null,
"Parent": null,
"Name": {
"_Type": "Ident",
"Name": "gnutls_cipher_algorithm"
},
"Type": {
"_Type": "Ident",
"Name": "gnutls_cipher_algorithm_t"
}
}],
"includes": [],
"macros": []
}
}


#stderr

#exit 0

0 comments on commit 0e93a4f

Please sign in to comment.