mirror of
https://github.com/Z3Prover/z3
synced 2026-02-17 06:11:44 +00:00
Add Go bindings to API coherence checker workflow
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
This commit is contained in:
parent
47469a3876
commit
479a6d3d3b
2 changed files with 58 additions and 53 deletions
8
.github/workflows/api-coherence-checker.md
vendored
8
.github/workflows/api-coherence-checker.md
vendored
|
|
@ -40,7 +40,7 @@ steps:
|
|||
|
||||
Your name is ${{ github.workflow }}. You are an expert AI agent tasked with checking coherence between the APIs exposed for different programming languages in the Z3 theorem prover repository `${{ github.repository }}`.
|
||||
|
||||
Z3 provides bindings for multiple languages: **Java**, **.NET (C#)**, **C++**, **Python**, **TypeScript/JavaScript**, and **OCaml**. Your job is to identify API features that are supported in some languages but missing in others, and suggest updates to improve API consistency.
|
||||
Z3 provides bindings for multiple languages: **Java**, **.NET (C#)**, **C++**, **Python**, **TypeScript/JavaScript**, **OCaml**, and **Go**. Your job is to identify API features that are supported in some languages but missing in others, and suggest updates to improve API consistency.
|
||||
|
||||
## Your Task
|
||||
|
||||
|
|
@ -78,6 +78,7 @@ The API implementations are located in:
|
|||
- **Python**: `src/api/python/z3/*.py` (mainly `z3.py`)
|
||||
- **TypeScript/JavaScript**: `src/api/js/src/**/*.ts`
|
||||
- **OCaml**: `src/api/ml/*.ml` and `*.mli` (interface files)
|
||||
- **Go**: `src/api/go/*.go` (CGO bindings)
|
||||
|
||||
### 4. Analyze API Coherence
|
||||
|
||||
|
|
@ -92,6 +93,7 @@ For each selected API family:
|
|||
- **C# (.NET)**: Use Serena to analyze C# classes and methods
|
||||
- **C++**: Use grep/glob to search for function declarations in `z3++.h`
|
||||
- **OCaml**: Use grep/glob to search for function definitions in `.ml` and `.mli` files
|
||||
- **Go**: Use grep/glob to search for function and method definitions in `src/api/go/*.go` files
|
||||
|
||||
3. **Compare implementations** across languages:
|
||||
- Is the same functionality available in all languages?
|
||||
|
|
@ -168,7 +170,7 @@ Store in cache memory:
|
|||
## Summary
|
||||
Analyzed: Solver APIs, BitVector operations, Context creation
|
||||
Total functions checked: 18
|
||||
Languages covered: 6
|
||||
Languages covered: 7
|
||||
Previously cached issues resolved: 2
|
||||
Inconsistencies found: 7
|
||||
|
||||
|
|
@ -186,7 +188,7 @@ The following cached issues have been resolved since the last run:
|
|||
|
||||
### 1. Missing BitVector Sign Extension in TypeScript
|
||||
**What**: Bit sign extension function `Z3_mk_sign_ext` is not exposed in TypeScript
|
||||
**Available in**: C, C++, Python, .NET, Java
|
||||
**Available in**: C, C++, Python, .NET, Java, Go
|
||||
**Missing in**: TypeScript
|
||||
**Fix**: Add `signExt(int i)` method to `BitVecExpr` class
|
||||
**File**: `src/api/js/src/high-level/`
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue