diff --git a/.claude/skills/update-llgo-version.md b/.claude/skills/update-llgo-version.md index 19a3d5517..efecda71f 100644 --- a/.claude/skills/update-llgo-version.md +++ b/.claude/skills/update-llgo-version.md @@ -1,11 +1,11 @@ --- name: update-llgo-version -description: Update the github.com/goplus/llgo dependency version across the llcppg project — Go module, CI workflows, and setup action. Use this skill whenever the user asks to bump, update, or upgrade the llgo version, or mentions changing the llgo dependency, even if they don't use the exact phrase "update llgo version". +description: Update the github.com/xgo-dev/llgo dependency version across the llcppg project — Go module, CI workflows, and setup action. Use this skill whenever the user asks to bump, update, or upgrade the llgo version, or mentions changing the llgo dependency, even if they don't use the exact phrase "update llgo version". --- # Update LLGo Version -Update `github.com/goplus/llgo` to a new version across the entire project. Six files reference the llgo version and they all need to stay in sync. +Update `github.com/xgo-dev/llgo` to a new version across the entire project. Six files reference the llgo version and they all need to stay in sync. ## Instructions @@ -13,14 +13,14 @@ Given a target version (e.g., `v0.14.0`): ### Step 1: Detect the current version -Read `go.mod` and note the current `github.com/goplus/llgo` version — you'll need it for the commit message. +Read `go.mod` and note the current `github.com/xgo-dev/llgo` version — you'll need it for the commit message. ### Step 2: Update Go module dependency Use `go get` to update the module dependency, then tidy: ```bash -go get github.com/goplus/llgo@ +go get github.com/xgo-dev/llgo@ go mod tidy ``` @@ -56,7 +56,7 @@ These are the fast unit tests. If they pass, the version bump is safe to commit. ## Commit Convention ``` -build(deps): bump github.com/goplus/llgo from to +build(deps): bump github.com/xgo-dev/llgo from to ``` Replace `` with the version you noted in Step 1 and `` with the target version. diff --git a/.github/actions/setup-llcppg/action.yml b/.github/actions/setup-llcppg/action.yml index 82652dd3b..6c3f75a71 100644 --- a/.github/actions/setup-llcppg/action.yml +++ b/.github/actions/setup-llcppg/action.yml @@ -3,13 +3,13 @@ description: "Install dependencies, set up Go, download LLGo release, install ll inputs: go: description: "Go version to install" - default: "1.23" + default: "1.27" llvm: description: "LLVM version to install (e.g. 18)" default: "19" llgo: description: "LLGo version to download (e.g. v0.13.0)" - default: "v0.13.0" + default: "v1.0.1" runs: using: "composite" steps: diff --git a/.github/actions/setup-llcppg/download-llgo.sh b/.github/actions/setup-llcppg/download-llgo.sh index 3c05febc8..cfa19ce9e 100755 --- a/.github/actions/setup-llcppg/download-llgo.sh +++ b/.github/actions/setup-llcppg/download-llgo.sh @@ -39,7 +39,7 @@ esac # Remove 'v' prefix from version if present VERSION_NUMBER="${VERSION#v}" FILENAME="llgo${VERSION_NUMBER}.${OS}-${ARCH}.tar.gz" -URL="https://github.com/goplus/llgo/releases/download/${VERSION}/${FILENAME}" +URL="https://github.com/xgo-dev/llgo/releases/download/${VERSION}/${FILENAME}" echo "Downloading LLGo ${VERSION} for ${OS}-${ARCH}..." echo "URL: $URL" diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index 561e5c421..0864a4164 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -5,7 +5,7 @@ Always reference these instructions first and fallback to search or bash command ## Working Effectively ### Bootstrap Dependencies and Build -llcppg requires LLGo (https://github.com/goplus/llgo) and specific LLVM version. Follow these exact steps: +llcppg requires LLGo (https://github.com/xgo-dev/llgo) and specific LLVM version. Follow these exact steps: - Install system dependencies (Ubuntu/Linux): ```bash @@ -25,7 +25,7 @@ llcppg requires LLGo (https://github.com/goplus/llgo) and specific LLVM version. - Clone and install LLGo (CRITICAL dependency): ```bash - git clone https://github.com/goplus/llgo.git .llgo + git clone https://github.com/xgo-dev/llgo.git .llgo cd .llgo git checkout 298669b02c41190b2be623fcacace56a01ced3d7 go install -v ./cmd/llgo/... diff --git a/.github/workflows/end2end.yml b/.github/workflows/end2end.yml index 1b6ea9192..86e204e74 100644 --- a/.github/workflows/end2end.yml +++ b/.github/workflows/end2end.yml @@ -19,7 +19,6 @@ jobs: strategy: matrix: os: - - macos-15-intel - macos-latest - ubuntu-latest - ubuntu-24.04-arm diff --git a/.github/workflows/gentest.yml b/.github/workflows/gentest.yml index c3e0fce4a..2333b4ffb 100644 --- a/.github/workflows/gentest.yml +++ b/.github/workflows/gentest.yml @@ -19,8 +19,6 @@ jobs: strategy: matrix: os: - - macos-15-intel - - macos-latest - ubuntu-latest - ubuntu-24.04-arm llvm: [19] diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 4276cbb4a..cde198f39 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -75,7 +75,7 @@ jobs: uses: codecov/codecov-action@v5 with: token: ${{secrets.CODECOV_TOKEN}} - slug: goplus/llcppg + slug: xgo-dev/llcppg - name: Test demos run: bash .github/workflows/test_demo.sh diff --git a/README.md b/README.md index 5288282aa..ef19cadb6 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,11 @@ llcppg - LLGo autogen tool for C/C++ libraries ==== -[![Build Status](https://github.com/goplus/llcppg/actions/workflows/go.yml/badge.svg)](https://github.com/goplus/llcppg/actions/workflows/go.yml) -[![Go Report Card](https://goreportcard.com/badge/github.com/goplus/llcppg)](https://goreportcard.com/report/github.com/goplus/llcppg) -[![GitHub release](https://img.shields.io/github/v/tag/goplus/llcppg.svg?label=release)](https://github.com/goplus/llcppg/releases) -[![Coverage Status](https://codecov.io/gh/goplus/llcppg/branch/main/graph/badge.svg)](https://codecov.io/gh/goplus/llcppg) -[![Language](https://img.shields.io/badge/language-XGo-blue.svg)](https://github.com/goplus/gop) -[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/goplus/llcppg) +[![Build Status](https://github.com/xgo-dev/llcppg/actions/workflows/go.yml/badge.svg)](https://github.com/xgo-dev/llcppg/actions/workflows/go.yml) +[![GitHub release](https://img.shields.io/github/v/tag/xgo-dev/llcppg.svg?label=release)](https://github.com/xgo-dev/llcppg/releases) +[![Coverage Status](https://codecov.io/gh/xgo-dev/llcppg/branch/main/graph/badge.svg)](https://codecov.io/gh/xgo-dev/llcppg) +[![GoDoc](https://pkg.go.dev/badge/github.com/xgo-dev/llcppg.svg)](https://pkg.go.dev/github.com/xgo-dev/llcppg) +[![XGo](https://img.shields.io/badge/project-XGo-blue.svg)](https://github.com/goplus/xgo) llcppg aims to be a tool for automatically generating LLGo bindings for C/C++ libraries, enhancing the experience of integrating LLGo with C! It is worth mentioning that the full llcppg package-generation pipeline is now built and orchestrated with LLGo. @@ -17,7 +16,7 @@ This project depends on LLGo's C ecosystem integration capability, and the curre llcppg currently follows the latest LLGo main-branch behavior. Please build and install LLGo from the `main` branch first, then install llcppg. For LLGo installation, please refer to: -https://github.com/goplus/llgo?tab=readme-ov-file#how-to-install +https://github.com/xgo-dev/llgo?tab=readme-ov-file#how-to-install ```bash llgo install ./cmd/llcppg @@ -337,14 +336,14 @@ When a header file in the current project references types from third-party pack * Otherwise, the user is notified of the missing type and its source header file for conversion. #### Special Dependency Aliases -In llcppg, there is a consistent pattern for naming aliases related to the standard library. Any alias that starts with `c/` corresponds to a remote repository in the github.com/goplus/llgo. +In llcppg, there is a consistent pattern for naming aliases related to the standard library. Any alias that starts with `c/` corresponds to a remote repository in the github.com/xgo-dev/llgo. For example: * The alias `c` → `github.com/goplus/lib/c` * The alias `c/os` → `github.com/goplus/lib/c/os` * The alias `c/time` → `github.com/goplus/lib/c/time` -> Note: Standard library type conversion in LLGo is not comprehensive. For standard library types that cannot be found in LLGo, you will need to supplement these types in the corresponding package at https://github.com/goplus/llgo. +> Note: Standard library type conversion in LLGo is not comprehensive. For standard library types that cannot be found in LLGo, you will need to supplement these types in the corresponding package at https://github.com/xgo-dev/llgo. #### Example You can specify dependent package paths in the `deps` field of `llcppg.cfg`. For example, in the `_llcppgtest/libxslt` example, since libxslt depends on libxml2, its configuration file looks like this: diff --git a/_cmptest/go.mod b/_cmptest/go.mod index f68cfd810..e780b5fd7 100644 --- a/_cmptest/go.mod +++ b/_cmptest/go.mod @@ -1,7 +1,10 @@ -module github.com/goplus/llcppg/_cmptest +module github.com/xgo-dev/llcppg/_cmptest -go 1.23.4 +go 1.27.0 -require github.com/goplus/llpkgstore v0.0.0-20250514100530-dd449df83ebf +require ( + github.com/goplus/llpkgstore v0.0.0-20250514100530-dd449df83ebf + github.com/xgo-dev/llcppg v0.0.0-00010101000000-000000000000 +) -require github.com/goplus/llcppg v0.5.0 +replace github.com/xgo-dev/llcppg => ../ diff --git a/_cmptest/go.sum b/_cmptest/go.sum index 5fe4ddc9c..1cc609e34 100644 --- a/_cmptest/go.sum +++ b/_cmptest/go.sum @@ -1,4 +1,2 @@ -github.com/goplus/llcppg v0.5.0 h1:IP4KUDOVw/JrkNvmCKbm9Kcv1lRIwPqeudSnt+nPC3g= -github.com/goplus/llcppg v0.5.0/go.mod h1:hC3O+B4dw6yQqjn+LpBC7Pw9eTPaDW+wXEfeAOyTqRo= github.com/goplus/llpkgstore v0.0.0-20250514100530-dd449df83ebf h1:l/RnlMqN7Fv7jlhHC6iqbjlUZ+NXZjcr4e987S6cqlE= github.com/goplus/llpkgstore v0.0.0-20250514100530-dd449df83ebf/go.mod h1:4VvozCteCpzqcoFbHW0dOcCjk3A7scMD9gCxjFggTkc= diff --git a/_cmptest/llcppgend_test.go b/_cmptest/llcppgend_test.go index 6515a1371..5db3e7445 100644 --- a/_cmptest/llcppgend_test.go +++ b/_cmptest/llcppgend_test.go @@ -12,9 +12,9 @@ import ( "sync" "testing" - "github.com/goplus/llcppg/config" "github.com/goplus/llpkgstore/upstream" "github.com/goplus/llpkgstore/upstream/installer/conan" + "github.com/xgo-dev/llcppg/config" ) const llcppgGoVersion = "1.20.14" @@ -34,7 +34,7 @@ type testCase struct { var testCases = []testCase{ { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/cjson/1.7.18/cjson", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/cjson/1.7.18/cjson", dir: "./testdata/cjson/1.7.18", pkg: upstream.Package{Name: "cjson", Version: "1.7.18"}, config: map[string]string{ @@ -43,7 +43,7 @@ var testCases = []testCase{ demosDir: "./testdata/cjson/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/cjson/1.7.17/cjson", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/cjson/1.7.17/cjson", dir: "./testdata/cjson/1.7.17", pkg: upstream.Package{Name: "cjson", Version: "1.7.17"}, config: map[string]string{ @@ -52,7 +52,7 @@ var testCases = []testCase{ demosDir: "./testdata/cjson/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2", dir: "./testdata/libxml2/2.13.6", pkg: upstream.Package{Name: "libxml2", Version: "2.13.6"}, config: map[string]string{ @@ -61,44 +61,44 @@ var testCases = []testCase{ demosDir: "./testdata/libxml2/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/sqlite3/3.49.1/sqlite3", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/sqlite3/3.49.1/sqlite3", dir: "./testdata/sqlite3/3.49.1", pkg: upstream.Package{Name: "sqlite3", Version: "3.49.1"}, demosDir: "./testdata/sqlite3/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/zlib/1.3.1/zlib", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/zlib/1.3.1/zlib", dir: "./testdata/zlib/1.3.1", pkg: upstream.Package{Name: "zlib", Version: "1.3.1"}, demosDir: "./testdata/zlib/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/bzip3/1.5.1/bzip3", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/bzip3/1.5.1/bzip3", dir: "./testdata/bzip3/1.5.1", pkg: upstream.Package{Name: "bzip3", Version: "1.5.1"}, demosDir: "./testdata/bzip3/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/cargs/1.2.0/cargs", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/cargs/1.2.0/cargs", dir: "./testdata/cargs/1.2.0", pkg: upstream.Package{Name: "cargs", Version: "1.2.0"}, demosDir: "./testdata/cargs/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/bzip2/1.0.8/bzip2", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/bzip2/1.0.8/bzip2", dir: "./testdata/bzip2/1.0.8", pkg: upstream.Package{Name: "bzip2", Version: "1.0.8"}, demosDir: "./testdata/bzip2/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/libxslt/1.1.42/libxslt", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/libxslt/1.1.42/libxslt", dir: "./testdata/libxslt/1.1.42", pkg: upstream.Package{Name: "libxslt", Version: "1.1.42"}, demosDir: "./testdata/libxslt/demo", }, { - modpath: "github.com/goplus/llcppg/_cmptest/testdata/libtool/2.4.7/libtool", + modpath: "github.com/xgo-dev/llcppg/_cmptest/testdata/libtool/2.4.7/libtool", dir: "./testdata/libtool/2.4.7", pkg: upstream.Package{Name: "libtool", Version: "2.4.7"}, demosDir: "./testdata/libtool/demo", @@ -312,7 +312,7 @@ func appendPCPath(path string) string { // llgo env func llgoEnv() []string { return []string{ - // for https://github.com/goplus/llgo/issues/1135 + // for https://github.com/xgo-dev/llgo/issues/1135 "LLGO_RPATH_CHANGE=on", } } diff --git a/_cmptest/testdata/bzip2/1.0.8/bzip2/go.mod b/_cmptest/testdata/bzip2/1.0.8/bzip2/go.mod index 84e8ad4f0..65cd53299 100644 --- a/_cmptest/testdata/bzip2/1.0.8/bzip2/go.mod +++ b/_cmptest/testdata/bzip2/1.0.8/bzip2/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/bzip2/1.0.8/bzip2 +module github.com/xgo-dev/llcppg/_cmptest/testdata/bzip2/1.0.8/bzip2 go 1.20 diff --git a/_cmptest/testdata/bzip3/1.5.1/bzip3/go.mod b/_cmptest/testdata/bzip3/1.5.1/bzip3/go.mod index a984bd1b9..bd72c7c63 100644 --- a/_cmptest/testdata/bzip3/1.5.1/bzip3/go.mod +++ b/_cmptest/testdata/bzip3/1.5.1/bzip3/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/bzip3/1.5.1/bzip3 +module github.com/xgo-dev/llcppg/_cmptest/testdata/bzip3/1.5.1/bzip3 go 1.20 diff --git a/_cmptest/testdata/cargs/1.2.0/cargs/go.mod b/_cmptest/testdata/cargs/1.2.0/cargs/go.mod index 7dbcf7638..420e7e016 100644 --- a/_cmptest/testdata/cargs/1.2.0/cargs/go.mod +++ b/_cmptest/testdata/cargs/1.2.0/cargs/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/cargs/1.2.0/cargs +module github.com/xgo-dev/llcppg/_cmptest/testdata/cargs/1.2.0/cargs go 1.20 diff --git a/_cmptest/testdata/cjson/1.7.17/cjson/go.mod b/_cmptest/testdata/cjson/1.7.17/cjson/go.mod index 2572c6a91..1280c1572 100644 --- a/_cmptest/testdata/cjson/1.7.17/cjson/go.mod +++ b/_cmptest/testdata/cjson/1.7.17/cjson/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/cjson/1.7.17/cjson +module github.com/xgo-dev/llcppg/_cmptest/testdata/cjson/1.7.17/cjson go 1.20 diff --git a/_cmptest/testdata/cjson/1.7.18/cjson/go.mod b/_cmptest/testdata/cjson/1.7.18/cjson/go.mod index 62f636c11..ab4b93e74 100644 --- a/_cmptest/testdata/cjson/1.7.18/cjson/go.mod +++ b/_cmptest/testdata/cjson/1.7.18/cjson/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/cjson/1.7.18/cjson +module github.com/xgo-dev/llcppg/_cmptest/testdata/cjson/1.7.18/cjson go 1.20 diff --git a/_cmptest/testdata/libtool/2.4.7/libtool/go.mod b/_cmptest/testdata/libtool/2.4.7/libtool/go.mod index 9d82fa1f6..d51267d7d 100644 --- a/_cmptest/testdata/libtool/2.4.7/libtool/go.mod +++ b/_cmptest/testdata/libtool/2.4.7/libtool/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/libtool/2.4.7/libtool +module github.com/xgo-dev/llcppg/_cmptest/testdata/libtool/2.4.7/libtool go 1.20 diff --git a/_cmptest/testdata/libxml2/2.13.6/libxml2/go.mod b/_cmptest/testdata/libxml2/2.13.6/libxml2/go.mod index c4bb7028b..2b3158cff 100644 --- a/_cmptest/testdata/libxml2/2.13.6/libxml2/go.mod +++ b/_cmptest/testdata/libxml2/2.13.6/libxml2/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2 +module github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2 go 1.20 diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/attributes.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/attributes.go index b09dfe637..11ed23e9e 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/attributes.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/attributes.go @@ -1,8 +1,9 @@ package libxslt import ( - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname ParseStylesheetAttributeSet C.xsltParseStylesheetAttributeSet diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/documents.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/documents.go index b4dc3c68a..c82c3482e 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/documents.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/documents.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname NewDocument C.xsltNewDocument diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/extensions.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/extensions.go index dfc3f6040..425577b46 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/extensions.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/extensions.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) /** diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/extra.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/extra.go index 5aff1c05b..c50e3edbc 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/extra.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/extra.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname FunctionNodeSet C.xsltFunctionNodeSet diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/functions.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/functions.go index 9e4d3ed0c..499b2aa7b 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/functions.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/functions.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname XPathFunctionLookup C.xsltXPathFunctionLookup diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/go.mod b/_cmptest/testdata/libxslt/1.1.42/libxslt/go.mod index 571dc4cff..e17debc85 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/go.mod +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/go.mod @@ -1,8 +1,8 @@ -module github.com/goplus/llcppg/_cmptest/testdata/libxslt/1.1.42/libxslt +module github.com/xgo-dev/llcppg/_cmptest/testdata/libxslt/1.1.42/libxslt go 1.20 require ( github.com/goplus/lib v0.3.1 - github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2 v0.0.0-20250605025807-6b6057874bf2 + github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2 v0.0.0-20250605025807-6b6057874bf2 ) diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/go.sum b/_cmptest/testdata/libxslt/1.1.42/libxslt/go.sum index cd22cff77..757c90920 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/go.sum +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/go.sum @@ -1,4 +1,4 @@ github.com/goplus/lib v0.3.1 h1:Xws4DBVvgOMu58awqB972wtvTacDbk3nqcbHjdx9KSg= github.com/goplus/lib v0.3.1/go.mod h1:SgJv3oPqLLHCu0gcL46ejOP3x7/2ry2Jtxu7ta32kp0= -github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2 v0.0.0-20250605025807-6b6057874bf2 h1:zSC9XzQPizHzBfrFWYghjeYdjPjQpnSBKp63ELYNIxg= -github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2 v0.0.0-20250605025807-6b6057874bf2/go.mod h1:0097o+5eelN3faOgyaWK3xXBqzYU68VCGLjbPyXtB0c= +github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2 v0.0.0-20250605025807-6b6057874bf2 h1:zSC9XzQPizHzBfrFWYghjeYdjPjQpnSBKp63ELYNIxg= +github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2 v0.0.0-20250605025807-6b6057874bf2/go.mod h1:0097o+5eelN3faOgyaWK3xXBqzYU68VCGLjbPyXtB0c= diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/imports.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/imports.go index bf7242efe..dc167b24f 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/imports.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/imports.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) /* diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/keys.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/keys.go index cbd4504cc..eff65affb 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/keys.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/keys.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname AddKey C.xsltAddKey diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/libxslt_autogen_link.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/libxslt_autogen_link.go index dc7e7c899..ca14d6771 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/libxslt_autogen_link.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/libxslt_autogen_link.go @@ -3,7 +3,7 @@ package libxslt import ( _ "github.com/goplus/lib/c" _ "github.com/goplus/lib/c/os" - _ "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" + _ "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) const LLGoPackage string = "link: $(pkg-config --libs libxslt);" diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/llcppg.cfg b/_cmptest/testdata/libxslt/1.1.42/libxslt/llcppg.cfg index 2e7c3dee6..0ec5ab1da 100755 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/llcppg.cfg +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/llcppg.cfg @@ -30,7 +30,7 @@ ], "trimPrefixes": ["XSLT_","xslt"], "cplusplus": false, - "deps": ["c/os","github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2@6b6057874bf2fd7fbc508e4c6adedfa229ad444b"], + "deps": ["c/os","github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2@6b6057874bf2fd7fbc508e4c6adedfa229ad444b"], "symMap":{ "xsltSetCtxtLocaleHandlers":"-" } diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/namespaces.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/namespaces.go index a16052cfa..b2c43b2d3 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/namespaces.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/namespaces.go @@ -1,8 +1,9 @@ package libxslt import ( - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname NamespaceAlias C.xsltNamespaceAlias diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/numbersInternals.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/numbersInternals.go index 36d8fca66..aef1e79c8 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/numbersInternals.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/numbersInternals.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) type X_xsltCompMatch struct { diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/pattern.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/pattern.go index c3a6ae723..32dffd83f 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/pattern.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/pattern.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) type CompMatch X_xsltCompMatch diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/preproc.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/preproc.go index 82bf51002..2f0cb7ba1 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/preproc.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/preproc.go @@ -1,8 +1,9 @@ package libxslt import ( - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname DocumentComp C.xsltDocumentComp diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/security.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/security.go index 1efeb1d37..6179bf82c 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/security.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/security.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) type X_xsltSecurityPrefs struct { diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/templates.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/templates.go index 6c4d9d955..35cdd011e 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/templates.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/templates.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname EvalXPathPredicate C.xsltEvalXPathPredicate diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/transform.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/transform.go index bd38d7ad4..d19bc3257 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/transform.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/transform.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) /** diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/variables.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/variables.go index be73a8eae..175a83a5e 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/variables.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/variables.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) const RVT_LOCAL = 1 diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltInternals.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltInternals.go index 23d360194..4c5e65793 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltInternals.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltInternals.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) const MAX_SORT = 15 diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltlocale.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltlocale.go index bb2635827..452adb8b3 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltlocale.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltlocale.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) //go:linkname NewLocale C.xsltNewLocale diff --git a/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltutils.go b/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltutils.go index 60fa3de59..75a3f65ed 100644 --- a/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltutils.go +++ b/_cmptest/testdata/libxslt/1.1.42/libxslt/xsltutils.go @@ -1,9 +1,10 @@ package libxslt import ( - "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" _ "unsafe" + + "github.com/goplus/lib/c" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) /* diff --git a/_cmptest/testdata/libxslt/demo/withdeplibxml2/main.go b/_cmptest/testdata/libxslt/demo/withdeplibxml2/main.go index 8df1a1987..ef391a26e 100644 --- a/_cmptest/testdata/libxslt/demo/withdeplibxml2/main.go +++ b/_cmptest/testdata/libxslt/demo/withdeplibxml2/main.go @@ -8,7 +8,7 @@ import ( "libxslt" "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" + "github.com/xgo-dev/llcppg/_cmptest/testdata/libxml2/2.13.6/libxml2" ) func main() { diff --git a/_cmptest/testdata/sqlite3/3.49.1/sqlite3/go.mod b/_cmptest/testdata/sqlite3/3.49.1/sqlite3/go.mod index 75ca15071..5b4ffbfdc 100644 --- a/_cmptest/testdata/sqlite3/3.49.1/sqlite3/go.mod +++ b/_cmptest/testdata/sqlite3/3.49.1/sqlite3/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/sqlite3/3.49.1/sqlite3 +module github.com/xgo-dev/llcppg/_cmptest/testdata/sqlite3/3.49.1/sqlite3 go 1.20 diff --git a/_cmptest/testdata/zlib/1.3.1/zlib/go.mod b/_cmptest/testdata/zlib/1.3.1/zlib/go.mod index 4f15eea1d..4fb236171 100644 --- a/_cmptest/testdata/zlib/1.3.1/zlib/go.mod +++ b/_cmptest/testdata/zlib/1.3.1/zlib/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_cmptest/testdata/zlib/1.3.1/zlib +module github.com/xgo-dev/llcppg/_cmptest/testdata/zlib/1.3.1/zlib go 1.20 diff --git a/_demo/cjsondemo/go.mod b/_demo/cjsondemo/go.mod index ef228d687..15ac05914 100644 --- a/_demo/cjsondemo/go.mod +++ b/_demo/cjsondemo/go.mod @@ -1,4 +1,4 @@ -module github.com/goplus/llcppg/_demo/cjsondemo +module github.com/xgo-dev/llcppg/_demo/cjsondemo go 1.20 diff --git a/_xtool/internal/clang/clang.go b/_xtool/internal/clang/clang.go index 667d3a9b5..ff3a64be2 100644 --- a/_xtool/internal/clang/clang.go +++ b/_xtool/internal/clang/clang.go @@ -6,8 +6,8 @@ import ( "unsafe" "github.com/goplus/lib/c" - "github.com/goplus/llcppg/_xtool/internal/clangtool" - clang "github.com/goplus/llcppg/_xtool/internal/libclang" + "github.com/xgo-dev/llcppg/_xtool/internal/clangtool" + clang "github.com/xgo-dev/llcppg/_xtool/internal/libclang" ) type Config struct { diff --git a/_xtool/internal/clang/clang_test.go b/_xtool/internal/clang/clang_test.go index 6008db66b..c8831179f 100644 --- a/_xtool/internal/clang/clang_test.go +++ b/_xtool/internal/clang/clang_test.go @@ -6,8 +6,8 @@ import ( "strings" "testing" - clangutils "github.com/goplus/llcppg/_xtool/internal/clang" - clang "github.com/goplus/llcppg/_xtool/internal/libclang" + clangutils "github.com/xgo-dev/llcppg/_xtool/internal/clang" + clang "github.com/xgo-dev/llcppg/_xtool/internal/libclang" ) func TestClangUtil(t *testing.T) { diff --git a/_xtool/internal/clangtool/clangtool_test.go b/_xtool/internal/clangtool/clangtool_test.go index 9037fe6ee..55eebbba0 100644 --- a/_xtool/internal/clangtool/clangtool_test.go +++ b/_xtool/internal/clangtool/clangtool_test.go @@ -5,7 +5,7 @@ import ( "reflect" "testing" - "github.com/goplus/llcppg/_xtool/internal/clangtool" + "github.com/xgo-dev/llcppg/_xtool/internal/clangtool" ) func TestComposeIncludes(t *testing.T) { diff --git a/_xtool/internal/header/header.go b/_xtool/internal/header/header.go index 12ade1758..5e20f0800 100644 --- a/_xtool/internal/header/header.go +++ b/_xtool/internal/header/header.go @@ -5,7 +5,7 @@ import ( "path/filepath" "strings" - "github.com/goplus/llcppg/_xtool/internal/clangtool" + "github.com/xgo-dev/llcppg/_xtool/internal/clangtool" ) type PkgHfilesInfo struct { diff --git a/_xtool/internal/header/header_test.go b/_xtool/internal/header/header_test.go index 293ddcd21..c8d930a36 100644 --- a/_xtool/internal/header/header_test.go +++ b/_xtool/internal/header/header_test.go @@ -7,8 +7,8 @@ import ( "strings" "testing" - "github.com/goplus/llcppg/_xtool/internal/header" - llconfig "github.com/goplus/llcppg/config" + "github.com/xgo-dev/llcppg/_xtool/internal/header" + llconfig "github.com/xgo-dev/llcppg/config" ) func TestPkgHfileInfo(t *testing.T) { diff --git a/_xtool/internal/ld/ld.go b/_xtool/internal/ld/ld.go index 09f77aaa3..cee7469c5 100644 --- a/_xtool/internal/ld/ld.go +++ b/_xtool/internal/ld/ld.go @@ -11,7 +11,7 @@ import ( func GetLibSearchPaths() []string { var paths []string if runtime.GOOS == "linux" { - //resolution from https://github.com/goplus/llcppg/commit/02307485db9269481297a4dc5e8449fffaa4f562 + //resolution from https://github.com/xgo-dev/llcppg/commit/02307485db9269481297a4dc5e8449fffaa4f562 cmd := exec.Command("ld", "--verbose") output, err := cmd.Output() if err != nil { diff --git a/_xtool/internal/ld/ld_test.go b/_xtool/internal/ld/ld_test.go index 58786ef58..45cb66f67 100644 --- a/_xtool/internal/ld/ld_test.go +++ b/_xtool/internal/ld/ld_test.go @@ -4,7 +4,7 @@ import ( "reflect" "testing" - "github.com/goplus/llcppg/_xtool/internal/ld" + "github.com/xgo-dev/llcppg/_xtool/internal/ld" ) func TestLdOutput(t *testing.T) { diff --git a/_xtool/internal/parser/marshal.go b/_xtool/internal/parser/marshal.go index 5c773e3d1..a7746c7d5 100644 --- a/_xtool/internal/parser/marshal.go +++ b/_xtool/internal/parser/marshal.go @@ -1,7 +1,7 @@ package parser import ( - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) func XMarshalDeclList(list []ast.Decl) []map[string]any { diff --git a/_xtool/internal/parser/parser.go b/_xtool/internal/parser/parser.go index 6617eda74..ce270fa74 100644 --- a/_xtool/internal/parser/parser.go +++ b/_xtool/internal/parser/parser.go @@ -9,10 +9,10 @@ import ( "unsafe" "github.com/goplus/lib/c" - clangutils "github.com/goplus/llcppg/_xtool/internal/clang" - clang "github.com/goplus/llcppg/_xtool/internal/libclang" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/token" + clangutils "github.com/xgo-dev/llcppg/_xtool/internal/clang" + clang "github.com/xgo-dev/llcppg/_xtool/internal/libclang" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/token" ) type dbgFlags = int @@ -288,7 +288,7 @@ func (ct *Converter) ProcessType(t clang.Type) ast.Expr { ct.logln("ProcessType: TypeName:", typeName, "TypeKind:", typeKind) if t.Kind == clang.TypeUnexposed { - // https://github.com/goplus/llcppg/issues/497 + // https://github.com/xgo-dev/llcppg/issues/497 return ct.ProcessType(t.CanonicalType()) } @@ -899,7 +899,7 @@ func (ct *Converter) ProcessElaboratedType(t clang.Type) ast.Expr { } // case 2: anonymous enum, nested (normal nested struct reference) // by default, the type of an anonymous enum is int - // NOTE(MeteorsLiu): see disscussion https://github.com/goplus/llcppg/pull/530 + // NOTE(MeteorsLiu): see disscussion https://github.com/xgo-dev/llcppg/pull/530 return &ast.BuiltinType{Kind: ast.Int} // case 3: named enum, nested, fallback to process as a ElaboratedType (nornaml nested struct) diff --git a/_xtool/internal/parser/parser_test.go b/_xtool/internal/parser/parser_test.go index 5cfc3ef98..659820115 100644 --- a/_xtool/internal/parser/parser_test.go +++ b/_xtool/internal/parser/parser_test.go @@ -11,17 +11,17 @@ import ( "testing" "github.com/goplus/lib/c" - clangutils "github.com/goplus/llcppg/_xtool/internal/clang" - "github.com/goplus/llcppg/_xtool/internal/clangtool" - clang "github.com/goplus/llcppg/_xtool/internal/libclang" - "github.com/goplus/llcppg/_xtool/internal/parser" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llgo/xtool/clang/preprocessor" + clangutils "github.com/xgo-dev/llcppg/_xtool/internal/clang" + "github.com/xgo-dev/llcppg/_xtool/internal/clangtool" + clang "github.com/xgo-dev/llcppg/_xtool/internal/libclang" + "github.com/xgo-dev/llcppg/_xtool/internal/parser" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llgo/xtool/clang/preprocessor" ) func TestParserCppMode(t *testing.T) { cases := []string{"class", "comment", "enum", "func", "scope", "struct", "typedef", "union", "macro", "forwarddecl1", "forwarddecl2", "include", "typeof", "forward_vs_empty", "nestedenum_cpp"} - // https://github.com/goplus/llgo/issues/1114 + // https://github.com/xgo-dev/llgo/issues/1114 // todo(zzy):use os.ReadDir for _, folder := range cases { t.Run(folder, func(t *testing.T) { @@ -57,7 +57,7 @@ func testFrom(t *testing.T, dir string, filename string, isCpp, gen bool) { if err != nil { t.Fatal("Do failed:", err) } - // https://github.com/goplus/llgo/issues/1116 + // https://github.com/xgo-dev/llgo/issues/1116 // astJson, err := json.MarshalIndent(ast, "", " ") // todo(zzy):use json.Marshal if err != nil { diff --git a/_xtool/internal/parser/testdata/typeof/expect.json b/_xtool/internal/parser/testdata/typeof/expect.json index 00053e908..6d76db265 100755 --- a/_xtool/internal/parser/testdata/typeof/expect.json +++ b/_xtool/internal/parser/testdata/typeof/expect.json @@ -5,7 +5,7 @@ "Doc": { "List": [ { - "Text": "// https://github.com/goplus/llcppg/issues/497", + "Text": "// https://github.com/xgo-dev/llcppg/issues/497", "_Type": "Comment" } ], diff --git a/_xtool/internal/parser/testdata/typeof/temp.h b/_xtool/internal/parser/testdata/typeof/temp.h index ab5fa1db7..6e0c52fba 100644 --- a/_xtool/internal/parser/testdata/typeof/temp.h +++ b/_xtool/internal/parser/testdata/typeof/temp.h @@ -1,4 +1,4 @@ -// https://github.com/goplus/llcppg/issues/497 +// https://github.com/xgo-dev/llcppg/issues/497 typedef struct { int x; union { diff --git a/_xtool/llclang/internal/parser/iparser.go b/_xtool/llclang/internal/parser/iparser.go index 8be6c3525..4162ec403 100644 --- a/_xtool/llclang/internal/parser/iparser.go +++ b/_xtool/llclang/internal/parser/iparser.go @@ -5,8 +5,8 @@ import ( "fmt" "strconv" - cparser "github.com/goplus/llcppg/_xtool/internal/parser" - "github.com/goplus/llcppg/parser" + cparser "github.com/xgo-dev/llcppg/_xtool/internal/parser" + "github.com/xgo-dev/llcppg/parser" ) type Mode = parser.Mode diff --git a/_xtool/llclang/llclang.go b/_xtool/llclang/llclang.go index b00ec451f..e10b2ad5a 100644 --- a/_xtool/llclang/llclang.go +++ b/_xtool/llclang/llclang.go @@ -4,7 +4,7 @@ import ( "fmt" "os" - "github.com/goplus/llcppg/_xtool/llclang/internal/parser" + "github.com/xgo-dev/llcppg/_xtool/llclang/internal/parser" ) /* diff --git a/_xtool/llcppsigfetch/llcppsigfetch.go b/_xtool/llcppsigfetch/llcppsigfetch.go index 406a68ac2..4eb387ef9 100644 --- a/_xtool/llcppsigfetch/llcppsigfetch.go +++ b/_xtool/llcppsigfetch/llcppsigfetch.go @@ -22,10 +22,10 @@ import ( "path/filepath" "strings" - clangutils "github.com/goplus/llcppg/_xtool/internal/clang" - "github.com/goplus/llcppg/_xtool/parse" - llcppg "github.com/goplus/llcppg/config" - args "github.com/goplus/llcppg/internal/arg" + clangutils "github.com/xgo-dev/llcppg/_xtool/internal/clang" + "github.com/xgo-dev/llcppg/_xtool/parse" + llcppg "github.com/xgo-dev/llcppg/config" + args "github.com/xgo-dev/llcppg/internal/arg" ) func main() { diff --git a/_xtool/llcppsymg/llcppsymg.go b/_xtool/llcppsymg/llcppsymg.go index b5f4cf596..f199682b7 100644 --- a/_xtool/llcppsymg/llcppsymg.go +++ b/_xtool/llcppsymg/llcppsymg.go @@ -21,9 +21,9 @@ import ( "fmt" "os" - "github.com/goplus/llcppg/_xtool/symg" - llcppg "github.com/goplus/llcppg/config" - args "github.com/goplus/llcppg/internal/arg" + "github.com/xgo-dev/llcppg/_xtool/symg" + llcppg "github.com/xgo-dev/llcppg/config" + args "github.com/xgo-dev/llcppg/internal/arg" ) func main() { diff --git a/_xtool/parse/dump.go b/_xtool/parse/dump.go index 52c3f356d..72d508e42 100644 --- a/_xtool/parse/dump.go +++ b/_xtool/parse/dump.go @@ -1,8 +1,8 @@ package parse import ( - "github.com/goplus/llcppg/_xtool/internal/parser" - llcppg "github.com/goplus/llcppg/config" + "github.com/xgo-dev/llcppg/_xtool/internal/parser" + llcppg "github.com/xgo-dev/llcppg/config" ) func MarshalPkg(pkg *llcppg.Pkg) map[string]any { diff --git a/_xtool/parse/parse.go b/_xtool/parse/parse.go index a0492244f..16c093884 100644 --- a/_xtool/parse/parse.go +++ b/_xtool/parse/parse.go @@ -6,11 +6,11 @@ import ( "os" "strings" - "github.com/goplus/llcppg/_xtool/internal/clangtool" - "github.com/goplus/llcppg/_xtool/internal/header" - "github.com/goplus/llcppg/_xtool/internal/parser" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llgo/xtool/clang/preprocessor" + "github.com/xgo-dev/llcppg/_xtool/internal/clangtool" + "github.com/xgo-dev/llcppg/_xtool/internal/header" + "github.com/xgo-dev/llcppg/_xtool/internal/parser" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llgo/xtool/clang/preprocessor" ) type dbgFlags = int @@ -110,7 +110,7 @@ func Do(conf *Config) error { return err } - // https://github.com/goplus/llgo/issues/603 + // https://github.com/xgo-dev/llgo/issues/603 // we need exec.Command("clang", "-print-resource-dir").Output() in llcppsigfetch to obtain the resource directory // to ensure consistency between clang preprocessing and libclang-extracted header filelink cflags. // Currently, directly calling exec.Command in the main flow of llcppsigfetch will cause hang and fail to execute correctly. diff --git a/_xtool/parse/parse_test.go b/_xtool/parse/parse_test.go index 943acd204..362bd5d9a 100644 --- a/_xtool/parse/parse_test.go +++ b/_xtool/parse/parse_test.go @@ -10,10 +10,10 @@ import ( "strings" "testing" - "github.com/goplus/llcppg/_xtool/internal/clangtool" - "github.com/goplus/llcppg/_xtool/internal/parser" - "github.com/goplus/llcppg/_xtool/parse" - llcppg "github.com/goplus/llcppg/config" + "github.com/xgo-dev/llcppg/_xtool/internal/clangtool" + "github.com/xgo-dev/llcppg/_xtool/internal/parser" + "github.com/xgo-dev/llcppg/_xtool/parse" + llcppg "github.com/xgo-dev/llcppg/config" ) func TestInclusionMap(t *testing.T) { diff --git a/_xtool/parse/testdata/sysinc/hfile/inc.h b/_xtool/parse/testdata/sysinc/hfile/inc.h index 564a22dd7..896bab2a6 100644 --- a/_xtool/parse/testdata/sysinc/hfile/inc.h +++ b/_xtool/parse/testdata/sysinc/hfile/inc.h @@ -1,3 +1,3 @@ -// todo(zzy): Wait for this issue to be resolved https://github.com/goplus/llgo/issues/603, then supplement tests for +// todo(zzy): Wait for this issue to be resolved https://github.com/xgo-dev/llgo/issues/603, then supplement tests for // stddef.h and stdio.h here #include diff --git a/_xtool/symg/lib.go b/_xtool/symg/lib.go index 20a0b0e20..6cf6a9dd2 100644 --- a/_xtool/symg/lib.go +++ b/_xtool/symg/lib.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - "github.com/goplus/llcppg/_xtool/internal/symbol" + "github.com/xgo-dev/llcppg/_xtool/internal/symbol" ) type Libs struct { diff --git a/_xtool/symg/lib_test.go b/_xtool/symg/lib_test.go index 0705c46db..566b19c5d 100644 --- a/_xtool/symg/lib_test.go +++ b/_xtool/symg/lib_test.go @@ -8,8 +8,8 @@ import ( "runtime" "testing" - "github.com/goplus/llcppg/_xtool/internal/symbol" - "github.com/goplus/llcppg/_xtool/symg" + "github.com/xgo-dev/llcppg/_xtool/internal/symbol" + "github.com/xgo-dev/llcppg/_xtool/symg" ) func TestParseLibs(t *testing.T) { diff --git a/_xtool/symg/parse.go b/_xtool/symg/parse.go index 78f2c8834..9193e48f6 100644 --- a/_xtool/symg/parse.go +++ b/_xtool/symg/parse.go @@ -7,11 +7,11 @@ import ( "strconv" "strings" - clangutils "github.com/goplus/llcppg/_xtool/internal/clang" - clang "github.com/goplus/llcppg/_xtool/internal/libclang" - "github.com/goplus/llcppg/internal/name" + clangutils "github.com/xgo-dev/llcppg/_xtool/internal/clang" + clang "github.com/xgo-dev/llcppg/_xtool/internal/libclang" + "github.com/xgo-dev/llcppg/internal/name" - llcppg "github.com/goplus/llcppg/config" + llcppg "github.com/xgo-dev/llcppg/config" ) type HeaderSymbols map[string]*SymbolInfo diff --git a/_xtool/symg/symg.go b/_xtool/symg/symg.go index 0d559f4b2..2e121cd9d 100644 --- a/_xtool/symg/symg.go +++ b/_xtool/symg/symg.go @@ -7,12 +7,12 @@ import ( "sort" "strings" - "github.com/goplus/llcppg/_xtool/internal/clangtool" - "github.com/goplus/llcppg/_xtool/internal/header" - "github.com/goplus/llcppg/_xtool/internal/ld" - "github.com/goplus/llcppg/_xtool/internal/symbol" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llgo/xtool/nm" + "github.com/xgo-dev/llcppg/_xtool/internal/clangtool" + "github.com/xgo-dev/llcppg/_xtool/internal/header" + "github.com/xgo-dev/llcppg/_xtool/internal/ld" + "github.com/xgo-dev/llcppg/_xtool/internal/symbol" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llgo/xtool/nm" ) type dbgFlags = int diff --git a/_xtool/symg/symg_test.go b/_xtool/symg/symg_test.go index 89f654faa..9781eb5b8 100644 --- a/_xtool/symg/symg_test.go +++ b/_xtool/symg/symg_test.go @@ -13,11 +13,11 @@ import ( "strings" "testing" - "github.com/goplus/llcppg/_xtool/internal/symbol" - "github.com/goplus/llcppg/_xtool/symg" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/name" - "github.com/goplus/llgo/xtool/nm" + "github.com/xgo-dev/llcppg/_xtool/internal/symbol" + "github.com/xgo-dev/llcppg/_xtool/symg" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/name" + "github.com/xgo-dev/llgo/xtool/nm" ) func TestAddSuffix(t *testing.T) { diff --git a/_xtool/symg/testdata/c/c.h b/_xtool/symg/testdata/c/c.h index 712fd2af4..375ad4995 100644 --- a/_xtool/symg/testdata/c/c.h +++ b/_xtool/symg/testdata/c/c.h @@ -17,7 +17,7 @@ Foo *Foo_ParseWithLength(const char *value, size_t buffer_length); Foo *Foo_ParseWithSize(const char *value, size_t buffer_length); Foo *Foo_ignoreFunc(); -// https://github.com/goplus/llcppg/issues/522 +// https://github.com/xgo-dev/llcppg/issues/522 Foo *Foo_ignoreFunc2(); diff --git a/ast/ast.go b/ast/ast.go index a7703ae04..12430329c 100644 --- a/ast/ast.go +++ b/ast/ast.go @@ -16,7 +16,7 @@ package ast -import "github.com/goplus/llcppg/token" +import "github.com/xgo-dev/llcppg/token" // ============================================================================= diff --git a/cl/blockctx.go b/cl/blockctx.go index 37de8307e..25ee174f1 100644 --- a/cl/blockctx.go +++ b/cl/blockctx.go @@ -20,7 +20,7 @@ import ( "go/token" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) type blockCtx struct { diff --git a/cl/compile.go b/cl/compile.go index 82f46f659..661d764fa 100644 --- a/cl/compile.go +++ b/cl/compile.go @@ -23,8 +23,8 @@ import ( "reflect" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/convert" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/convert" ) /* TODO(xsw): remove diff --git a/cl/convert.go b/cl/convert.go index 9f91aedc4..7986c6c88 100644 --- a/cl/convert.go +++ b/cl/convert.go @@ -1,9 +1,9 @@ package cl import ( - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/convert" - "github.com/goplus/llcppg/cl/nc" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/convert" + "github.com/xgo-dev/llcppg/cl/nc" ) const DbgFlagAll = convert.DbgFlagAll diff --git a/cl/decl.go b/cl/decl.go index f3d77575f..db3a39833 100644 --- a/cl/decl.go +++ b/cl/decl.go @@ -17,7 +17,7 @@ package cl import ( - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) func compileMacro(ctx *blockCtx, macro *ast.Macro) { diff --git a/cl/internal/cltest/cltest.go b/cl/internal/cltest/cltest.go index de86e99dc..86189bafb 100644 --- a/cl/internal/cltest/cltest.go +++ b/cl/internal/cltest/cltest.go @@ -1,10 +1,10 @@ package cltest import ( - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/nc" - "github.com/goplus/llcppg/cl/nc/ncimpl" - llcppg "github.com/goplus/llcppg/config" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/nc" + "github.com/xgo-dev/llcppg/cl/nc/ncimpl" + llcppg "github.com/xgo-dev/llcppg/config" ) func NewConvSym(syms ...llcppg.SymbolInfo) func(name *ast.Object, mangleName string) (goName string, err error) { diff --git a/cl/internal/convert/_testdata/_depcjson/conf/llcppg.cfg b/cl/internal/convert/_testdata/_depcjson/conf/llcppg.cfg index 468301b36..76a38313c 100644 --- a/cl/internal/convert/_testdata/_depcjson/conf/llcppg.cfg +++ b/cl/internal/convert/_testdata/_depcjson/conf/llcppg.cfg @@ -5,9 +5,9 @@ "libs": "$(pkg-config --libs libcjson)", "cplusplus":false, "deps": [ - "github.com/goplus/llcppg/cl/internal/convert/testdata/cjson", - "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep", - "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep2", - "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep3" + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/cjson", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep2", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep3" ] } diff --git a/cl/internal/convert/_testdata/_depcjson/gogensig.expect b/cl/internal/convert/_testdata/_depcjson/gogensig.expect index f27d5dce4..cd71234bb 100644 --- a/cl/internal/convert/_testdata/_depcjson/gogensig.expect +++ b/cl/internal/convert/_testdata/_depcjson/gogensig.expect @@ -13,10 +13,10 @@ package depcjson import ( _ "github.com/goplus/lib/c" - _ "github.com/goplus/llcppg/cl/internal/convert/testdata/cjson" - _ "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep" - _ "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep2" - _ "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep3" + _ "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/cjson" + _ "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep" + _ "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep2" + _ "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep3" ) const LLGoPackage string = "link: $(pkg-config --libs libcjson);" @@ -26,11 +26,11 @@ package depcjson import ( "github.com/goplus/lib/c" - "github.com/goplus/llcppg/cl/internal/convert/testdata/basicdep" - "github.com/goplus/llcppg/cl/internal/convert/testdata/cjson" - "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep" - "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep2" - "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep3" + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/basicdep" + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/cjson" + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep" + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep2" + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep3" _ "unsafe" ) diff --git a/cl/internal/convert/_testdata/forwarddecl/gogensig.expect b/cl/internal/convert/_testdata/forwarddecl/gogensig.expect index cc79f975c..eb07314c7 100644 --- a/cl/internal/convert/_testdata/forwarddecl/gogensig.expect +++ b/cl/internal/convert/_testdata/forwarddecl/gogensig.expect @@ -129,7 +129,7 @@ type X_xmlParserCtxt struct { type XmlParserCtxt X_xmlParserCtxt type HtmlParserCtxt XmlParserCtxt -// https://github.com/goplus/llcppg/issues/526 +// https://github.com/xgo-dev/llcppg/issues/526 type ForwardOnly struct { Unused [8]uint8 } diff --git a/cl/internal/convert/_testdata/forwarddecl/hfile/temp.h b/cl/internal/convert/_testdata/forwarddecl/hfile/temp.h index c52f48ff3..be9de7ee5 100644 --- a/cl/internal/convert/_testdata/forwarddecl/hfile/temp.h +++ b/cl/internal/convert/_testdata/forwarddecl/hfile/temp.h @@ -95,6 +95,6 @@ typedef struct _xmlParserCtxt xmlParserCtxt; typedef xmlParserCtxt htmlParserCtxt; -// https://github.com/goplus/llcppg/issues/526 +// https://github.com/xgo-dev/llcppg/issues/526 struct ForwardOnly; struct EmptyStruct {}; \ No newline at end of file diff --git a/cl/internal/convert/_testdata/methodreturn/gogensig.expect b/cl/internal/convert/_testdata/methodreturn/gogensig.expect index 1540cc95b..2d95f9875 100644 --- a/cl/internal/convert/_testdata/methodreturn/gogensig.expect +++ b/cl/internal/convert/_testdata/methodreturn/gogensig.expect @@ -15,7 +15,7 @@ import ( // origin field is float,but if use float,we will ref the c.Float // we only can get the c.Float's underlying type,not the c.Float -// so we use int to replace float, https://github.com/goplus/llcppg/issues/249 +// so we use int to replace float, https://github.com/xgo-dev/llcppg/issues/249 type Vector3 struct { X c.Int Y c.Int diff --git a/cl/internal/convert/_testdata/methodreturn/hfile/temp.h b/cl/internal/convert/_testdata/methodreturn/hfile/temp.h index 0bef43224..144f03ebd 100644 --- a/cl/internal/convert/_testdata/methodreturn/hfile/temp.h +++ b/cl/internal/convert/_testdata/methodreturn/hfile/temp.h @@ -1,6 +1,6 @@ // origin field is float,but if use float,we will ref the c.Float // we only can get the c.Float's underlying type,not the c.Float -// so we use int to replace float, https://github.com/goplus/llcppg/issues/249 +// so we use int to replace float, https://github.com/xgo-dev/llcppg/issues/249 typedef struct Vector3 { int x; int y; diff --git a/cl/internal/convert/_testdata/nested/gogensig.expect b/cl/internal/convert/_testdata/nested/gogensig.expect index b7736df2a..f5223a0f2 100644 --- a/cl/internal/convert/_testdata/nested/gogensig.expect +++ b/cl/internal/convert/_testdata/nested/gogensig.expect @@ -25,7 +25,7 @@ type InnerStruct struct { L c.Long } -// https://github.com/goplus/llcppg/issues/514 +// https://github.com/xgo-dev/llcppg/issues/514 // named nested struct type StructWithNested struct { Init InnerStruct @@ -77,7 +77,7 @@ type E struct { FField F } -// https://github.com/goplus/llcppg/issues/514 +// https://github.com/xgo-dev/llcppg/issues/514 type A struct { BField B EField E diff --git a/cl/internal/convert/_testdata/nested/hfile/temp.h b/cl/internal/convert/_testdata/nested/hfile/temp.h index 570de2134..b3d0ef9f4 100644 --- a/cl/internal/convert/_testdata/nested/hfile/temp.h +++ b/cl/internal/convert/_testdata/nested/hfile/temp.h @@ -11,7 +11,7 @@ struct struct1 }; -// https://github.com/goplus/llcppg/issues/514 +// https://github.com/xgo-dev/llcppg/issues/514 // named nested struct struct struct_with_nested { struct inner_struct { @@ -59,7 +59,7 @@ union union2 }; -// https://github.com/goplus/llcppg/issues/514 +// https://github.com/xgo-dev/llcppg/issues/514 struct a { struct b { struct c { diff --git a/cl/internal/convert/_testdata/receiver/hfile/use.h b/cl/internal/convert/_testdata/receiver/hfile/use.h index 98b3e2425..3ccfdb35a 100644 --- a/cl/internal/convert/_testdata/receiver/hfile/use.h +++ b/cl/internal/convert/_testdata/receiver/hfile/use.h @@ -2,7 +2,7 @@ const void *ares_dns_pton(const char *ipaddr, struct ares_addr *addr); char *ares_dns_addr_to_ptr(const struct ares_addr *addr); -// case for https://github.com/goplus/llcppg/issues/510 +// case for https://github.com/xgo-dev/llcppg/issues/510 typedef enum { ESP_LOG_NONE = 0, ESP_LOG_ERROR = 1, diff --git a/cl/internal/convert/_testdata/typeof/gogensig.expect b/cl/internal/convert/_testdata/typeof/gogensig.expect index d9c731fc8..ce476e5fa 100644 --- a/cl/internal/convert/_testdata/typeof/gogensig.expect +++ b/cl/internal/convert/_testdata/typeof/gogensig.expect @@ -6,7 +6,7 @@ import ( _ "unsafe" ) -// https://github.com/goplus/llcppg/issues/497 +// https://github.com/xgo-dev/llcppg/issues/497 type SpiMemDevT struct { X c.Int Clock struct { diff --git a/cl/internal/convert/_testdata/typeof/hfile/temp.h b/cl/internal/convert/_testdata/typeof/hfile/temp.h index ab5fa1db7..6e0c52fba 100644 --- a/cl/internal/convert/_testdata/typeof/hfile/temp.h +++ b/cl/internal/convert/_testdata/typeof/hfile/temp.h @@ -1,4 +1,4 @@ -// https://github.com/goplus/llcppg/issues/497 +// https://github.com/xgo-dev/llcppg/issues/497 typedef struct { int x; union { diff --git a/cl/internal/convert/builtin.go b/cl/internal/convert/builtin.go index bc4983e80..5b7e0b5d1 100644 --- a/cl/internal/convert/builtin.go +++ b/cl/internal/convert/builtin.go @@ -5,7 +5,7 @@ import ( "go/types" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) type BuiltinTypeMap struct { diff --git a/cl/internal/convert/builtin_test.go b/cl/internal/convert/builtin_test.go index 122a056da..b6150a399 100644 --- a/cl/internal/convert/builtin_test.go +++ b/cl/internal/convert/builtin_test.go @@ -4,8 +4,8 @@ import ( "go/types" "testing" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/convert" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/convert" ) func TestBuiltinType(t *testing.T) { diff --git a/cl/internal/convert/comments.go b/cl/internal/convert/comments.go index 8a634bf7c..fed754551 100644 --- a/cl/internal/convert/comments.go +++ b/cl/internal/convert/comments.go @@ -5,7 +5,7 @@ import ( "go/token" "strings" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) const ( diff --git a/cl/internal/convert/convert.go b/cl/internal/convert/convert.go index 15cc1ef7a..0fa211711 100644 --- a/cl/internal/convert/convert.go +++ b/cl/internal/convert/convert.go @@ -5,8 +5,8 @@ import ( "os" "os/exec" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/nc" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/nc" ) type dbgFlags = int diff --git a/cl/internal/convert/convert_builtin_test.go b/cl/internal/convert/convert_builtin_test.go index 26ef04131..9507cfa8c 100644 --- a/cl/internal/convert/convert_builtin_test.go +++ b/cl/internal/convert/convert_builtin_test.go @@ -7,10 +7,10 @@ import ( "strings" "testing" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/cltest" - "github.com/goplus/llcppg/cl/nc" - llcppg "github.com/goplus/llcppg/config" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/cltest" + "github.com/xgo-dev/llcppg/cl/nc" + llcppg "github.com/xgo-dev/llcppg/config" ) func basicConverter(pkg *ast.File, nc nc.NodeConverter) *Converter { diff --git a/cl/internal/convert/convert_test.go b/cl/internal/convert/convert_test.go index 3e51cb42c..5c3e4aa00 100644 --- a/cl/internal/convert/convert_test.go +++ b/cl/internal/convert/convert_test.go @@ -12,13 +12,13 @@ import ( "testing" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/cltest" - "github.com/goplus/llcppg/cl/internal/convert" - "github.com/goplus/llcppg/cmd/gogensig/unmarshal" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/gowrite" - "github.com/goplus/llgo/xtool/env" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/cltest" + "github.com/xgo-dev/llcppg/cl/internal/convert" + "github.com/xgo-dev/llcppg/cmd/gogensig/unmarshal" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/gowrite" + "github.com/xgo-dev/llgo/xtool/env" ) func init() { @@ -371,16 +371,16 @@ func prepareEnv(name string, deps []string) (string, error) { } // with the same module to import the internal/testdata/pkg - err = runCommand(outputDir, "go", "mod", "init", "github.com/goplus/llcppg/cl/internal/"+name) + err = runCommand(outputDir, "go", "mod", "init", "github.com/xgo-dev/llcppg/cl/internal/"+name) if err != nil { return "", err } - err = runCommand(outputDir, "go", "get", "github.com/goplus/llcppg") + err = runCommand(outputDir, "go", "get", "github.com/xgo-dev/llcppg") if err != nil { return "", err } - err = runCommand(outputDir, "go", "mod", "edit", "-replace", "github.com/goplus/llcppg="+projectRoot) + err = runCommand(outputDir, "go", "mod", "edit", "-replace", "github.com/xgo-dev/llcppg="+projectRoot) if err != nil { return "", err } diff --git a/cl/internal/convert/deps.go b/cl/internal/convert/deps.go index 629eb1dff..4fae5b54c 100644 --- a/cl/internal/convert/deps.go +++ b/cl/internal/convert/deps.go @@ -12,7 +12,7 @@ import ( "strings" "github.com/goplus/gogen" - llcppg "github.com/goplus/llcppg/config" + llcppg "github.com/xgo-dev/llcppg/config" ) type PkgDepLoader struct { @@ -43,7 +43,7 @@ type PkgInfo struct { } type PkgBase struct { - PkgPath string // package path, e.g. github.com/goplus/llgo/cjson + PkgPath string // package path, e.g. github.com/xgo-dev/llgo/cjson Deps []string // dependent packages Pubs map[string]string // llcppg.pub } diff --git a/cl/internal/convert/expr.go b/cl/internal/convert/expr.go index a7858a8aa..95f10354a 100644 --- a/cl/internal/convert/expr.go +++ b/cl/internal/convert/expr.go @@ -4,7 +4,7 @@ import ( "fmt" "strconv" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) type LitParseError struct { diff --git a/cl/internal/convert/expr_test.go b/cl/internal/convert/expr_test.go index f53bdf10a..2fc207874 100644 --- a/cl/internal/convert/expr_test.go +++ b/cl/internal/convert/expr_test.go @@ -4,8 +4,8 @@ import ( "reflect" "testing" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/convert" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/convert" ) func TestBasicLitFail(t *testing.T) { diff --git a/cl/internal/convert/funcname.go b/cl/internal/convert/funcname.go index 69c24c9b7..3e5b08589 100644 --- a/cl/internal/convert/funcname.go +++ b/cl/internal/convert/funcname.go @@ -3,7 +3,7 @@ package convert import ( "strings" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) // GoFuncSpec parses and stores components of a Go function name diff --git a/cl/internal/convert/package.go b/cl/internal/convert/package.go index 14b467ffd..c58c4d4f8 100644 --- a/cl/internal/convert/package.go +++ b/cl/internal/convert/package.go @@ -9,10 +9,10 @@ import ( goast "go/ast" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/nc" - "github.com/goplus/llcppg/internal/name" - ctoken "github.com/goplus/llcppg/token" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/nc" + "github.com/xgo-dev/llcppg/internal/name" + ctoken "github.com/xgo-dev/llcppg/token" ) // In Processing Package @@ -134,7 +134,7 @@ func (p *Package) newReceiver(typ *ast.FuncType) (*types.Var, error) { if err != nil { return nil, fmt.Errorf("newReceiver:failed to convert type: %w", err) } - return p.p.NewParam(token.NoPos, "recv_", recvType), nil + return p.p.NewParam(token.NoPos, "recv_", recvType, false), nil } func (p *Package) ToSigSignature(recv *types.Var, funcDecl *ast.FuncDecl) (*types.Signature, error) { @@ -336,7 +336,7 @@ func (p *Package) lookupType(name string, pnc nc.NodeConverter) (types.Type, err } // in third hfile but not have converted go type if path, ok := pnc.Lookup(name); ok { - return nil, fmt.Errorf("convert %s first, declare converted package in llcppg.cfg deps for load [%s]. See: https://github.com/goplus/llcppg#dependency", path, name) + return nil, fmt.Errorf("convert %s first, declare converted package in llcppg.cfg deps for load [%s]. See: https://github.com/xgo-dev/llcppg#dependency", path, name) } // implicit forward decl decl := p.handleImplicitForwardDecl(name, pnc) diff --git a/cl/internal/convert/package_bulitin_test.go b/cl/internal/convert/package_bulitin_test.go index eb7f7408a..734c6020e 100644 --- a/cl/internal/convert/package_bulitin_test.go +++ b/cl/internal/convert/package_bulitin_test.go @@ -9,13 +9,13 @@ import ( "testing" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/cltest" - "github.com/goplus/llcppg/cl/nc" - "github.com/goplus/llcppg/cl/nc/ncimpl" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/name" - ctoken "github.com/goplus/llcppg/token" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/cltest" + "github.com/xgo-dev/llcppg/cl/nc" + "github.com/xgo-dev/llcppg/cl/nc/ncimpl" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/name" + ctoken "github.com/xgo-dev/llcppg/token" ) func emptyPkg(nc nc.NodeConverter) *Package { diff --git a/cl/internal/convert/package_test.go b/cl/internal/convert/package_test.go index af40e18e8..af0b27e04 100644 --- a/cl/internal/convert/package_test.go +++ b/cl/internal/convert/package_test.go @@ -8,14 +8,14 @@ import ( "testing" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/cltest" - "github.com/goplus/llcppg/cl/internal/convert" - "github.com/goplus/llcppg/cl/nc" - "github.com/goplus/llcppg/cl/nc/ncimpl" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/name" - "github.com/goplus/llcppg/token" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/cltest" + "github.com/xgo-dev/llcppg/cl/internal/convert" + "github.com/xgo-dev/llcppg/cl/nc" + "github.com/xgo-dev/llcppg/cl/nc/ncimpl" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/name" + "github.com/xgo-dev/llcppg/token" ) var dir string @@ -1973,8 +1973,8 @@ func TestImport(t *testing.T) { t.Run("invalid include path", func(t *testing.T) { genPkg := gogen.NewPackage(".", "include", nil) deps := []string{ - "github.com/goplus/llcppg/cl/internal/convert/testdata/invalidpath", - "github.com/goplus/llcppg/cl/internal/convert/testdata/partfinddep", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/invalidpath", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/partfinddep", } _, err := convert.NewPkgDepLoader(".", genPkg, deps) if err == nil { @@ -1984,7 +1984,7 @@ func TestImport(t *testing.T) { t.Run("unknown import path", func(t *testing.T) { genPkg := gogen.NewPackage(".", "include", nil) deps := []string{ - "github.com/goplus/llcppg/cl/internal/convert/testdata/cjson", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/cjson", } loader, err := convert.NewPkgDepLoader(".", genPkg, deps) if err != nil { @@ -2000,7 +2000,7 @@ func TestImport(t *testing.T) { OutputDir: ".", PkgBase: convert.PkgBase{ Deps: []string{ - "github.com/goplus/llcppg/cl/internal/convert/testdata/invalidpub", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/invalidpub", }, }, }) @@ -2013,7 +2013,7 @@ func TestImport(t *testing.T) { OutputDir: ".", PkgBase: convert.PkgBase{ Deps: []string{ - "github.com/goplus/llcppg/cl/internal/convert/testdata/invaliddep", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/invaliddep", }, }, }) @@ -2026,8 +2026,8 @@ func TestImport(t *testing.T) { OutputDir: ".", PkgBase: convert.PkgBase{ Deps: []string{ - "github.com/goplus/llcppg/cl/internal/convert/testdata/cjson", - "github.com/goplus/llcppg/cl/internal/convert/testdata/cjsonbool", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/cjson", + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/cjsonbool", }, }, }) diff --git a/cl/internal/convert/testdata/invaliddep/llcppg.cfg b/cl/internal/convert/testdata/invaliddep/llcppg.cfg index b77bbfa4f..49838f92d 100644 --- a/cl/internal/convert/testdata/invaliddep/llcppg.cfg +++ b/cl/internal/convert/testdata/invaliddep/llcppg.cfg @@ -1,6 +1,6 @@ { "name": "invaliddep", "cplusplus":false, - "deps":["github.com/goplus/llcppg/cl/internal/convert/testdata/invalidcfg"], + "deps":["github.com/xgo-dev/llcppg/cl/internal/convert/testdata/invalidcfg"], "headerOnly": true } diff --git a/cl/internal/convert/testdata/thirddep/llcppg.cfg b/cl/internal/convert/testdata/thirddep/llcppg.cfg index f7b418028..16588661d 100644 --- a/cl/internal/convert/testdata/thirddep/llcppg.cfg +++ b/cl/internal/convert/testdata/thirddep/llcppg.cfg @@ -4,7 +4,7 @@ "type.h", "thirddep.h" ], - "deps":["github.com/goplus/llcppg/cl/internal/convert/testdata/basicdep"], + "deps":["github.com/xgo-dev/llcppg/cl/internal/convert/testdata/basicdep"], "cplusplus": false, "headerOnly": true } diff --git a/cl/internal/convert/testdata/thirddep2/llcppg.cfg b/cl/internal/convert/testdata/thirddep2/llcppg.cfg index 7649ab885..afd655dea 100644 --- a/cl/internal/convert/testdata/thirddep2/llcppg.cfg +++ b/cl/internal/convert/testdata/thirddep2/llcppg.cfg @@ -4,7 +4,7 @@ "type.h", "thirddep2.h" ], - "deps":["github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep","github.com/goplus/llcppg/cl/internal/convert/testdata/basicdep"], + "deps":["github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep","github.com/xgo-dev/llcppg/cl/internal/convert/testdata/basicdep"], "cplusplus": false, "headerOnly": true } diff --git a/cl/internal/convert/testdata/thirddep2/thirddep2.go b/cl/internal/convert/testdata/thirddep2/thirddep2.go index dafa648d5..8eb0dd272 100644 --- a/cl/internal/convert/testdata/thirddep2/thirddep2.go +++ b/cl/internal/convert/testdata/thirddep2/thirddep2.go @@ -3,8 +3,8 @@ package thirddep2 import ( _ "unsafe" - "github.com/goplus/llcppg/cl/internal/convert/testdata/basicdep" - "github.com/goplus/llcppg/cl/internal/convert/testdata/thirddep" + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/basicdep" + "github.com/xgo-dev/llcppg/cl/internal/convert/testdata/thirddep" ) type ThirdDep2 struct { diff --git a/cl/internal/convert/type.go b/cl/internal/convert/type.go index 1eed976b6..a8264f808 100644 --- a/cl/internal/convert/type.go +++ b/cl/internal/convert/type.go @@ -13,9 +13,9 @@ import ( "unsafe" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/nc" - "github.com/goplus/llcppg/internal/name" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/nc" + "github.com/xgo-dev/llcppg/internal/name" ) type TypeContext int diff --git a/cl/internal/convert/type_builtin_test.go b/cl/internal/convert/type_builtin_test.go index 6185d120f..8c91ac50f 100644 --- a/cl/internal/convert/type_builtin_test.go +++ b/cl/internal/convert/type_builtin_test.go @@ -6,9 +6,9 @@ import ( "testing" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/internal/cltest" - llcppg "github.com/goplus/llcppg/config" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/internal/cltest" + llcppg "github.com/xgo-dev/llcppg/config" ) func TestIdentRef(t *testing.T) { diff --git a/cl/nc/ncimpl/headerfile.go b/cl/nc/ncimpl/headerfile.go index 5332caf5c..2b57f6f98 100644 --- a/cl/nc/ncimpl/headerfile.go +++ b/cl/nc/ncimpl/headerfile.go @@ -1,8 +1,8 @@ package ncimpl import ( - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/name" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/name" ) type HeaderFile struct { diff --git a/cl/nc/ncimpl/ncimpl.go b/cl/nc/ncimpl/ncimpl.go index 16ced370f..047494c26 100644 --- a/cl/nc/ncimpl/ncimpl.go +++ b/cl/nc/ncimpl/ncimpl.go @@ -4,10 +4,10 @@ import ( "log" "strings" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/nc" - llconfig "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/name" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/nc" + llconfig "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/name" ) type ThirdTypeLoc struct { diff --git a/cl/nc/ncimpl/ncimpl_test.go b/cl/nc/ncimpl/ncimpl_test.go index 7cd283304..1b7f42073 100644 --- a/cl/nc/ncimpl/ncimpl_test.go +++ b/cl/nc/ncimpl/ncimpl_test.go @@ -4,9 +4,9 @@ import ( "errors" "testing" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl/nc" - llconfig "github.com/goplus/llcppg/config" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl/nc" + llconfig "github.com/xgo-dev/llcppg/config" ) func TestHeaderFile(t *testing.T) { diff --git a/cl/nc/nodeconv.go b/cl/nc/nodeconv.go index 3b308df27..e80dd346f 100644 --- a/cl/nc/nodeconv.go +++ b/cl/nc/nodeconv.go @@ -3,7 +3,7 @@ package nc import ( "errors" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) var ( diff --git a/cl/type_and_var.go b/cl/type_and_var.go index 2b61005a7..e00a25852 100644 --- a/cl/type_and_var.go +++ b/cl/type_and_var.go @@ -20,7 +20,7 @@ package cl import ( "go/types" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) func toType(ctx *blockCtx, typ ast.Expr, flags int) types.Type { diff --git a/cmd/gogensig/gogensig.go b/cmd/gogensig/gogensig.go index d0df1b920..62e9e6674 100644 --- a/cmd/gogensig/gogensig.go +++ b/cmd/gogensig/gogensig.go @@ -25,14 +25,14 @@ import ( "strings" "github.com/goplus/gogen" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl" - "github.com/goplus/llcppg/cl/nc/ncimpl" - "github.com/goplus/llcppg/cmd/gogensig/unmarshal" - llcppg "github.com/goplus/llcppg/config" - args "github.com/goplus/llcppg/internal/arg" - "github.com/goplus/llcppg/internal/gowrite" "github.com/qiniu/x/errors" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl" + "github.com/xgo-dev/llcppg/cl/nc/ncimpl" + "github.com/xgo-dev/llcppg/cmd/gogensig/unmarshal" + llcppg "github.com/xgo-dev/llcppg/config" + args "github.com/xgo-dev/llcppg/internal/arg" + "github.com/xgo-dev/llcppg/internal/gowrite" ) func main() { diff --git a/cmd/gogensig/gogensig_test.go b/cmd/gogensig/gogensig_test.go index 6dbd42ff4..c593da99d 100644 --- a/cmd/gogensig/gogensig_test.go +++ b/cmd/gogensig/gogensig_test.go @@ -12,7 +12,7 @@ import ( "strings" "testing" - llconfig "github.com/goplus/llcppg/config" + llconfig "github.com/xgo-dev/llcppg/config" ) func TestMain(t *testing.T) { diff --git a/cmd/gogensig/testdata/sqlite/hfile/sqlite3ext.h b/cmd/gogensig/testdata/sqlite/hfile/sqlite3ext.h index b1b9eff50..8a13d3ace 100644 --- a/cmd/gogensig/testdata/sqlite/hfile/sqlite3ext.h +++ b/cmd/gogensig/testdata/sqlite/hfile/sqlite3ext.h @@ -157,7 +157,7 @@ struct sqlite3_api_routines { const void * (*value_text16be)(sqlite3_value*); const void * (*value_text16le)(sqlite3_value*); int (*value_type)(sqlite3_value*); - // https://github.com/goplus/llcppg/issues/68 va_list not patch cause struct convert error + // https://github.com/xgo-dev/llcppg/issues/68 va_list not patch cause struct convert error // char *(*vmprintf)(const char*,va_list); /* Added ??? */ int (*overload_function)(sqlite3*, const char *zFuncName, int nArg); @@ -247,7 +247,7 @@ struct sqlite3_api_routines { int (*uri_boolean)(const char*,const char*,int); sqlite3_int64 (*uri_int64)(const char*,const char*,sqlite3_int64); const char *(*uri_parameter)(const char*,const char*); - // https://github.com/goplus/llcppg/issues/68 va_list not patch cause struct convert error + // https://github.com/xgo-dev/llcppg/issues/68 va_list not patch cause struct convert error // char *(*xvsnprintf)(int,char*,const char*,va_list); int (*wal_checkpoint_v2)(sqlite3*,const char*,int,int*,int*); /* Version 3.8.7 and later */ @@ -304,7 +304,7 @@ struct sqlite3_api_routines { sqlite3_str *(*str_new)(sqlite3*); char *(*str_finish)(sqlite3_str*); void (*str_appendf)(sqlite3_str*, const char *zFormat, ...); - // https://github.com/goplus/llcppg/issues/68 va_list not patch cause struct convert error + // https://github.com/xgo-dev/llcppg/issues/68 va_list not patch cause struct convert error // void (*str_vappendf)(sqlite3_str*, const char *zFormat, va_list); void (*str_append)(sqlite3_str*, const char *zIn, int N); void (*str_appendall)(sqlite3_str*, const char *zIn); diff --git a/cmd/gogensig/unmarshal/unmarshal.go b/cmd/gogensig/unmarshal/unmarshal.go index 6f5c656ae..c77738283 100644 --- a/cmd/gogensig/unmarshal/unmarshal.go +++ b/cmd/gogensig/unmarshal/unmarshal.go @@ -4,8 +4,8 @@ import ( "encoding/json" "fmt" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/unmarshal" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/unmarshal" ) func Pkg(data []byte) (*llcppg.Pkg, error) { diff --git a/cmd/gogensig/unmarshal/unmarshal_test.go b/cmd/gogensig/unmarshal/unmarshal_test.go index 3c18efddf..3f74c9341 100644 --- a/cmd/gogensig/unmarshal/unmarshal_test.go +++ b/cmd/gogensig/unmarshal/unmarshal_test.go @@ -5,9 +5,9 @@ import ( "strings" "testing" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cmd/gogensig/unmarshal" - llcppg "github.com/goplus/llcppg/config" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cmd/gogensig/unmarshal" + llcppg "github.com/xgo-dev/llcppg/config" ) func TestUnmarshalPkg(t *testing.T) { diff --git a/cmd/llcppcfg/gen/cfg.go b/cmd/llcppcfg/gen/cfg.go index f0993bab3..5840babed 100644 --- a/cmd/llcppcfg/gen/cfg.go +++ b/cmd/llcppcfg/gen/cfg.go @@ -12,7 +12,7 @@ import ( "strings" "unicode" - llcppg "github.com/goplus/llcppg/config" + llcppg "github.com/xgo-dev/llcppg/config" ) type Config struct { diff --git a/cmd/llcppcfg/gen/cfg_test.go b/cmd/llcppcfg/gen/cfg_test.go index 7a5d5ed77..f682c5553 100644 --- a/cmd/llcppcfg/gen/cfg_test.go +++ b/cmd/llcppcfg/gen/cfg_test.go @@ -9,7 +9,7 @@ import ( "strings" "testing" - llcppg "github.com/goplus/llcppg/config" + llcppg "github.com/xgo-dev/llcppg/config" ) func Test_emptyStringError_Error(t *testing.T) { diff --git a/cmd/llcppcfg/llcppcfg.go b/cmd/llcppcfg/llcppcfg.go index ec0933f15..1ebc0a725 100644 --- a/cmd/llcppcfg/llcppcfg.go +++ b/cmd/llcppcfg/llcppcfg.go @@ -6,7 +6,7 @@ import ( "os" "strings" - "github.com/goplus/llcppg/cmd/llcppcfg/gen" + "github.com/xgo-dev/llcppg/cmd/llcppcfg/gen" ) func printHelp() { diff --git a/cmd/llcppg/llcppg.go b/cmd/llcppg/llcppg.go index 6955a12c6..02f8d672e 100644 --- a/cmd/llcppg/llcppg.go +++ b/cmd/llcppg/llcppg.go @@ -25,15 +25,15 @@ import ( "path/filepath" "github.com/goplus/gogen" - "github.com/goplus/llcppg/_xtool/parse" - "github.com/goplus/llcppg/_xtool/symg" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/cl" - "github.com/goplus/llcppg/cl/nc/ncimpl" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/gowrite" - "github.com/goplus/llgo/xtool/env" "github.com/qiniu/x/errors" + "github.com/xgo-dev/llcppg/_xtool/parse" + "github.com/xgo-dev/llcppg/_xtool/symg" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/cl" + "github.com/xgo-dev/llcppg/cl/nc/ncimpl" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/gowrite" + "github.com/xgo-dev/llgo/xtool/env" // import to make it linked in go.mod _ "github.com/goplus/lib/c" diff --git a/cmd/llcppgtest/demo/demo.go b/cmd/llcppgtest/demo/demo.go index ab83f63de..ea2b7d650 100644 --- a/cmd/llcppgtest/demo/demo.go +++ b/cmd/llcppgtest/demo/demo.go @@ -10,7 +10,7 @@ import ( "strings" "sync" - llcppg "github.com/goplus/llcppg/config" + llcppg "github.com/xgo-dev/llcppg/config" ) var mkdirTempLazily = sync.OnceValue(func() string { diff --git a/cmd/llcppgtest/llcppgtest.go b/cmd/llcppgtest/llcppgtest.go index 77765ce9d..8ab2aee02 100644 --- a/cmd/llcppgtest/llcppgtest.go +++ b/cmd/llcppgtest/llcppgtest.go @@ -12,7 +12,7 @@ import ( "sync" "time" - "github.com/goplus/llcppg/cmd/llcppgtest/demo" + "github.com/xgo-dev/llcppg/cmd/llcppgtest/demo" ) type FlagName string diff --git a/config/config.go b/config/config.go index ae703d724..f6e2f1440 100644 --- a/config/config.go +++ b/config/config.go @@ -4,7 +4,7 @@ import ( "encoding/json" "fmt" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) const LLCPPG_CFG = "llcppg.cfg" diff --git a/config/config_test.go b/config/config_test.go index 40aedfa67..3bcddcea5 100644 --- a/config/config_test.go +++ b/config/config_test.go @@ -8,7 +8,7 @@ import ( "reflect" "testing" - llconfig "github.com/goplus/llcppg/config" + llconfig "github.com/xgo-dev/llcppg/config" ) type testMode int diff --git a/doc/en/dev/llcppg.md b/doc/en/dev/llcppg.md index 3bb86ad06..1af19be41 100644 --- a/doc/en/dev/llcppg.md +++ b/doc/en/dev/llcppg.md @@ -252,7 +252,7 @@ Named nested enums in C are accessible in the global scope, not just within the **Reason**: In C, named nested enums are declared in the global scope and can be used independently. This means the enum type can be used anywhere in the code, not just within the context of the outer struct. -**NOTE:** Should we add type alias here in the future? See discussion: [#530](https://github.com/goplus/llcppg/pull/530) +**NOTE:** Should we add type alias here in the future? See discussion: [#530](https://github.com/xgo-dev/llcppg/pull/530) ```c typedef struct Config { @@ -564,14 +564,14 @@ When a header file in the current project references types from third-party pack * Otherwise, the user is notified of the missing type and its source header file for conversion. #### Special Dependency Aliases -In llcppg, there is a consistent pattern for naming aliases related to the standard library. Any alias that starts with `c/` corresponds to a remote repository in the github.com/goplus/llgo. +In llcppg, there is a consistent pattern for naming aliases related to the standard library. Any alias that starts with `c/` corresponds to a remote repository in the github.com/xgo-dev/llgo. For example: * The alias `c` → `github.com/goplus/lib/c` * The alias `c/os` → `github.com/goplus/lib/c/os` * The alias `c/time` → `github.com/goplus/lib/c/time` -> Note: Standard library type conversion in LLGo is not comprehensive. For standard library types that cannot be found in LLGo, you will need to supplement these types in the corresponding package at https://github.com/goplus/llgo. +> Note: Standard library type conversion in LLGo is not comprehensive. For standard library types that cannot be found in LLGo, you will need to supplement these types in the corresponding package at https://github.com/xgo-dev/llgo. #### Example You can specify dependent package paths in the `deps` field of `llcppg.cfg`. For example, in the `_llcppgtest/libxslt` example, since libxslt depends on libxml2, its configuration file looks like this: diff --git a/go.mod b/go.mod index cd094e988..fbdc0038b 100644 --- a/go.mod +++ b/go.mod @@ -1,10 +1,10 @@ -module github.com/goplus/llcppg +module github.com/xgo-dev/llcppg -go 1.23.0 +go 1.27.0 require ( - github.com/goplus/gogen v1.21.2 - github.com/goplus/lib v0.3.1 - github.com/goplus/llgo v0.13.0 - github.com/qiniu/x v1.16.5 + github.com/goplus/gogen v1.23.5 + github.com/goplus/lib v0.5.0 + github.com/qiniu/x v1.18.3 + github.com/xgo-dev/llgo v1.0.1 ) diff --git a/go.sum b/go.sum index 91175f8a3..b38055d29 100644 --- a/go.sum +++ b/go.sum @@ -1,8 +1,8 @@ -github.com/goplus/gogen v1.21.2 h1:xbXPgZOZiQx/WBM0nZxVSxFbtdCMZCRB+lguDnh8pfs= -github.com/goplus/gogen v1.21.2/go.mod h1:Y7ulYW3wonQ3d9er00b0uGFEV/IUZa6okWJZh892ACQ= -github.com/goplus/lib v0.3.1 h1:Xws4DBVvgOMu58awqB972wtvTacDbk3nqcbHjdx9KSg= -github.com/goplus/lib v0.3.1/go.mod h1:SgJv3oPqLLHCu0gcL46ejOP3x7/2ry2Jtxu7ta32kp0= -github.com/goplus/llgo v0.13.0 h1:FYT9fe6IuYTXuDRPF/v8VFGeL61cVSrwITxDqEahKiw= -github.com/goplus/llgo v0.13.0/go.mod h1:HwCxwsxvUcZ4k6E16TbGsvhGBvaLszKDVmDPMCp82M8= -github.com/qiniu/x v1.16.5 h1:+/cSm9m8F8sx6zJ4ylmsuhux8xVpxMHP/pzL8xv1Y9w= -github.com/qiniu/x v1.16.5/go.mod h1:AiovSOCaRijaf3fj+0CBOpR1457pn24b0Vdb1JpwhII= +github.com/goplus/gogen v1.23.5 h1:76w3zmAHI+ECI7bPr0enUd0du9+t1IYyXmp43CbIpSs= +github.com/goplus/gogen v1.23.5/go.mod h1:Y7ulYW3wonQ3d9er00b0uGFEV/IUZa6okWJZh892ACQ= +github.com/goplus/lib v0.5.0 h1:zM8LAPatB4m8D/RflgDCSk6bJU1dEf7vzY6wqetO1WM= +github.com/goplus/lib v0.5.0/go.mod h1:SgJv3oPqLLHCu0gcL46ejOP3x7/2ry2Jtxu7ta32kp0= +github.com/qiniu/x v1.18.3 h1:trrBKBNszHGwV8XynnbddJr+A7Vca8/xlWP4F/Z4my8= +github.com/qiniu/x v1.18.3/go.mod h1:Sx3Wy+0GI9OsX4a53mYj6A0o7mHJ94PUvraqGYb4EIs= +github.com/xgo-dev/llgo v1.0.1 h1:EoxwjXTjsdSndToEPJ9iPjvRLfgEtAPlT4jP30yi0yg= +github.com/xgo-dev/llgo v1.0.1/go.mod h1:ujlTWPEQdYIporyTyu1q/WailHO5bXHfefcTd1lNaWA= diff --git a/internal/arg/arg_test.go b/internal/arg/arg_test.go index 4c30f5f95..ca8fede00 100644 --- a/internal/arg/arg_test.go +++ b/internal/arg/arg_test.go @@ -5,8 +5,8 @@ import ( "reflect" "testing" - llcppg "github.com/goplus/llcppg/config" - "github.com/goplus/llcppg/internal/arg" + llcppg "github.com/xgo-dev/llcppg/config" + "github.com/xgo-dev/llcppg/internal/arg" ) func TestParseArgs(t *testing.T) { diff --git a/internal/gowrite/gowrite_test.go b/internal/gowrite/gowrite_test.go index 5d4cc82e9..ae4317816 100644 --- a/internal/gowrite/gowrite_test.go +++ b/internal/gowrite/gowrite_test.go @@ -37,7 +37,7 @@ func InitHooks() { func TestWriteTo_NonEmptyFuncStaysMultiline(t *testing.T) { pkg := gogen.NewPackage("", "demo", nil) - results := types.NewTuple(pkg.NewParam(token.NoPos, "", types.Typ[types.Int])) + results := types.NewTuple(pkg.NewParam(token.NoPos, "", types.Typ[types.Int], false)) pkg.NewFunc(nil, "RetZero", nil, results, false).BodyStart(pkg).Val(0).Return(1).End() var buf bytes.Buffer diff --git a/internal/name/name_test.go b/internal/name/name_test.go index dd3e5c1a0..cf9854bf8 100644 --- a/internal/name/name_test.go +++ b/internal/name/name_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - "github.com/goplus/llcppg/internal/name" + "github.com/xgo-dev/llcppg/internal/name" ) func TestToGoName(t *testing.T) { diff --git a/internal/unmarshal/unmarshal.go b/internal/unmarshal/unmarshal.go index d42ec955e..19d22d861 100644 --- a/internal/unmarshal/unmarshal.go +++ b/internal/unmarshal/unmarshal.go @@ -5,7 +5,7 @@ import ( "fmt" "reflect" - "github.com/goplus/llcppg/ast" + "github.com/xgo-dev/llcppg/ast" ) type NodeUnmarshaler func(data []byte) (ast.Node, error) diff --git a/internal/unmarshal/unmarshal_test.go b/internal/unmarshal/unmarshal_test.go index cb02d9416..aad1a318a 100644 --- a/internal/unmarshal/unmarshal_test.go +++ b/internal/unmarshal/unmarshal_test.go @@ -5,8 +5,8 @@ import ( "strings" "testing" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/internal/unmarshal" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/internal/unmarshal" ) func TestUnmarshalFile(t *testing.T) { diff --git a/parser/iparser.go b/parser/iparser.go index 5e1eaff13..5acc97b23 100644 --- a/parser/iparser.go +++ b/parser/iparser.go @@ -23,8 +23,8 @@ import ( "os/exec" "strconv" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/internal/unmarshal" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/internal/unmarshal" ) // Mode represents the parsing mode. diff --git a/parser/parser.go b/parser/parser.go index bf8b6e3cd..1188f1b67 100644 --- a/parser/parser.go +++ b/parser/parser.go @@ -19,8 +19,8 @@ package parser import ( "go/token" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llgo/xtool/clang/preprocessor" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llgo/xtool/clang/preprocessor" ) // Config represents the configuration for parsing C/C++ source files. diff --git a/parser/parser_test.go b/parser/parser_test.go index 12cb593fd..55b84e677 100644 --- a/parser/parser_test.go +++ b/parser/parser_test.go @@ -3,8 +3,8 @@ package parser_test import ( "testing" - "github.com/goplus/llcppg/ast" - "github.com/goplus/llcppg/parser" + "github.com/xgo-dev/llcppg/ast" + "github.com/xgo-dev/llcppg/parser" ) func TestParseFile(t *testing.T) { diff --git a/tool/gengo.go b/tool/gengo.go index 5fed67a32..249a8bafe 100644 --- a/tool/gengo.go +++ b/tool/gengo.go @@ -21,11 +21,11 @@ import ( "path/filepath" "github.com/goplus/gogen" - "github.com/goplus/llcppg/cl" - "github.com/goplus/llcppg/cl/nc" - "github.com/goplus/llcppg/internal/gowrite" - "github.com/goplus/llcppg/parser" "github.com/qiniu/x/errors" + "github.com/xgo-dev/llcppg/cl" + "github.com/xgo-dev/llcppg/cl/nc" + "github.com/xgo-dev/llcppg/internal/gowrite" + "github.com/xgo-dev/llcppg/parser" ) // Config is the configuration for generating Go code from C++ header files.