IncludeCPP 3.7.3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of IncludeCPP might be problematic. Click here for more details.
- includecpp/__init__.py +59 -0
- includecpp/__init__.pyi +255 -0
- includecpp/__main__.py +4 -0
- includecpp/cli/__init__.py +4 -0
- includecpp/cli/commands.py +8270 -0
- includecpp/cli/config_parser.py +127 -0
- includecpp/core/__init__.py +19 -0
- includecpp/core/ai_integration.py +2132 -0
- includecpp/core/build_manager.py +2416 -0
- includecpp/core/cpp_api.py +376 -0
- includecpp/core/cpp_api.pyi +95 -0
- includecpp/core/cppy_converter.py +3448 -0
- includecpp/core/cssl/CSSL_DOCUMENTATION.md +2075 -0
- includecpp/core/cssl/__init__.py +42 -0
- includecpp/core/cssl/cssl_builtins.py +2271 -0
- includecpp/core/cssl/cssl_builtins.pyi +1393 -0
- includecpp/core/cssl/cssl_events.py +621 -0
- includecpp/core/cssl/cssl_modules.py +2803 -0
- includecpp/core/cssl/cssl_parser.py +2575 -0
- includecpp/core/cssl/cssl_runtime.py +3051 -0
- includecpp/core/cssl/cssl_syntax.py +488 -0
- includecpp/core/cssl/cssl_types.py +1512 -0
- includecpp/core/cssl_bridge.py +882 -0
- includecpp/core/cssl_bridge.pyi +488 -0
- includecpp/core/error_catalog.py +802 -0
- includecpp/core/error_formatter.py +1016 -0
- includecpp/core/exceptions.py +97 -0
- includecpp/core/path_discovery.py +77 -0
- includecpp/core/project_ui.py +3370 -0
- includecpp/core/settings_ui.py +326 -0
- includecpp/generator/__init__.py +1 -0
- includecpp/generator/parser.cpp +1903 -0
- includecpp/generator/parser.h +281 -0
- includecpp/generator/type_resolver.cpp +363 -0
- includecpp/generator/type_resolver.h +68 -0
- includecpp/py.typed +0 -0
- includecpp/templates/cpp.proj.template +18 -0
- includecpp/vscode/__init__.py +1 -0
- includecpp/vscode/cssl/__init__.py +1 -0
- includecpp/vscode/cssl/language-configuration.json +38 -0
- includecpp/vscode/cssl/package.json +50 -0
- includecpp/vscode/cssl/snippets/cssl.snippets.json +1080 -0
- includecpp/vscode/cssl/syntaxes/cssl.tmLanguage.json +341 -0
- includecpp-3.7.3.dist-info/METADATA +1076 -0
- includecpp-3.7.3.dist-info/RECORD +49 -0
- includecpp-3.7.3.dist-info/WHEEL +5 -0
- includecpp-3.7.3.dist-info/entry_points.txt +2 -0
- includecpp-3.7.3.dist-info/licenses/LICENSE +21 -0
- includecpp-3.7.3.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
#pragma once
|
|
2
|
+
#include <string>
|
|
3
|
+
#include <vector>
|
|
4
|
+
#include <set>
|
|
5
|
+
#include <regex>
|
|
6
|
+
#include "parser.h"
|
|
7
|
+
|
|
8
|
+
namespace includecpp {
|
|
9
|
+
namespace generator {
|
|
10
|
+
|
|
11
|
+
// Type String Parser - Parses C++ type strings into structured metadata
|
|
12
|
+
class TypeResolver {
|
|
13
|
+
public:
|
|
14
|
+
struct ParsedType {
|
|
15
|
+
std::string base_name; // "vector", "map", "Point"
|
|
16
|
+
bool is_template = false;
|
|
17
|
+
std::vector<ParsedType> template_args;
|
|
18
|
+
bool is_const = false;
|
|
19
|
+
bool is_reference = false;
|
|
20
|
+
bool is_pointer = false;
|
|
21
|
+
|
|
22
|
+
std::string to_cpp_string() const;
|
|
23
|
+
std::string to_python_hint() const;
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
// Parse type string: "const vector<Point<int>>&" → ParsedType
|
|
27
|
+
static ParsedType parse_type(const std::string& type_str);
|
|
28
|
+
|
|
29
|
+
// Type conversions
|
|
30
|
+
static std::string to_python_hint(const ParsedType& type);
|
|
31
|
+
static std::string to_pybind11_signature(const ParsedType& type);
|
|
32
|
+
static std::string strip_qualifiers(const std::string& type);
|
|
33
|
+
static std::string normalize_type(const std::string& type);
|
|
34
|
+
|
|
35
|
+
// Type queries
|
|
36
|
+
static bool is_container_type(const std::string& type);
|
|
37
|
+
static bool is_primitive_type(const std::string& type);
|
|
38
|
+
static bool is_numeric_type(const std::string& type);
|
|
39
|
+
static bool requires_custom_converter(const ParsedType& type);
|
|
40
|
+
|
|
41
|
+
private:
|
|
42
|
+
static std::vector<std::string> split_template_args(const std::string& args);
|
|
43
|
+
static std::string extract_template_content(const std::string& type_str);
|
|
44
|
+
static std::string to_lower(const std::string& str);
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
// Container Bindings Generator - Generates pybind11 bindings for STL containers
|
|
48
|
+
class ContainerBindings {
|
|
49
|
+
public:
|
|
50
|
+
// Generate pybind11 bindings for containers
|
|
51
|
+
static std::string generate_vector_binding(const std::string& element_type,
|
|
52
|
+
const std::string& module_var);
|
|
53
|
+
|
|
54
|
+
static std::string generate_map_binding(const std::string& key_type,
|
|
55
|
+
const std::string& value_type,
|
|
56
|
+
const std::string& module_var);
|
|
57
|
+
|
|
58
|
+
static std::string generate_nested_container_binding(const TypeMetadata& type,
|
|
59
|
+
const std::string& module_var);
|
|
60
|
+
|
|
61
|
+
// Helper: Detect which containers are used in module
|
|
62
|
+
static std::set<std::string> find_used_containers(const ModuleDescriptor& module);
|
|
63
|
+
|
|
64
|
+
private:
|
|
65
|
+
static std::string sanitize_type_name(const std::string& type);
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
}} // namespace includecpp::generator
|
includecpp/py.typed
ADDED
|
File without changes
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
{
|
|
2
|
+
"project": "MyProject",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"include": "/include",
|
|
5
|
+
"plugins": "/plugins",
|
|
6
|
+
"compiler": {
|
|
7
|
+
"standard": "c++17",
|
|
8
|
+
"optimization": "O3",
|
|
9
|
+
"flags": ["-Wall", "-pthread"]
|
|
10
|
+
},
|
|
11
|
+
"types": {
|
|
12
|
+
"common": ["int", "float", "double", "string"]
|
|
13
|
+
},
|
|
14
|
+
"threading": {
|
|
15
|
+
"enabled": true,
|
|
16
|
+
"max_workers": 8
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
# VSCode extension resources for CSSL
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
# CSSL VSCode extension files
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
{
|
|
2
|
+
"comments": {
|
|
3
|
+
"lineComment": "//",
|
|
4
|
+
"blockComment": ["/*", "*/"]
|
|
5
|
+
},
|
|
6
|
+
"brackets": [
|
|
7
|
+
["{", "}"],
|
|
8
|
+
["[", "]"],
|
|
9
|
+
["(", ")"],
|
|
10
|
+
["<", ">"]
|
|
11
|
+
],
|
|
12
|
+
"autoClosingPairs": [
|
|
13
|
+
{ "open": "{", "close": "}" },
|
|
14
|
+
{ "open": "[", "close": "]" },
|
|
15
|
+
{ "open": "(", "close": ")" },
|
|
16
|
+
{ "open": "<", "close": ">" },
|
|
17
|
+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
|
|
18
|
+
{ "open": "'", "close": "'", "notIn": ["string", "comment"] }
|
|
19
|
+
],
|
|
20
|
+
"surroundingPairs": [
|
|
21
|
+
["{", "}"],
|
|
22
|
+
["[", "]"],
|
|
23
|
+
["(", ")"],
|
|
24
|
+
["<", ">"],
|
|
25
|
+
["\"", "\""],
|
|
26
|
+
["'", "'"]
|
|
27
|
+
],
|
|
28
|
+
"folding": {
|
|
29
|
+
"markers": {
|
|
30
|
+
"start": "^\\s*//\\s*#?region\\b",
|
|
31
|
+
"end": "^\\s*//\\s*#?endregion\\b"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"indentationRules": {
|
|
35
|
+
"increaseIndentPattern": "^.*\\{[^}]*$",
|
|
36
|
+
"decreaseIndentPattern": "^\\s*\\}"
|
|
37
|
+
}
|
|
38
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "cssl",
|
|
3
|
+
"displayName": "CSSL - CSO Service Script Language",
|
|
4
|
+
"description": "Professional syntax highlighting, snippets, and language support for CSSL scripts (.cssl, .cssl-pl, .cssl-mod)",
|
|
5
|
+
"version": "1.1.0",
|
|
6
|
+
"publisher": "IncludeCPP",
|
|
7
|
+
"icon": "images/cssl-icon.png",
|
|
8
|
+
"engines": {
|
|
9
|
+
"vscode": "^1.60.0"
|
|
10
|
+
},
|
|
11
|
+
"categories": [
|
|
12
|
+
"Programming Languages",
|
|
13
|
+
"Snippets"
|
|
14
|
+
],
|
|
15
|
+
"keywords": [
|
|
16
|
+
"cssl",
|
|
17
|
+
"cso",
|
|
18
|
+
"script",
|
|
19
|
+
"includecpp",
|
|
20
|
+
"c++",
|
|
21
|
+
"python"
|
|
22
|
+
],
|
|
23
|
+
"contributes": {
|
|
24
|
+
"languages": [
|
|
25
|
+
{
|
|
26
|
+
"id": "cssl",
|
|
27
|
+
"aliases": ["CSSL", "cssl", "CSO Service Script"],
|
|
28
|
+
"extensions": [".cssl", ".cssl-pl", ".cssl-mod"],
|
|
29
|
+
"configuration": "./language-configuration.json",
|
|
30
|
+
"icon": {
|
|
31
|
+
"light": "./images/cssl-icon.png",
|
|
32
|
+
"dark": "./images/cssl-icon.png"
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
],
|
|
36
|
+
"grammars": [
|
|
37
|
+
{
|
|
38
|
+
"language": "cssl",
|
|
39
|
+
"scopeName": "source.cssl",
|
|
40
|
+
"path": "./syntaxes/cssl.tmLanguage.json"
|
|
41
|
+
}
|
|
42
|
+
],
|
|
43
|
+
"snippets": [
|
|
44
|
+
{
|
|
45
|
+
"language": "cssl",
|
|
46
|
+
"path": "./snippets/cssl.snippets.json"
|
|
47
|
+
}
|
|
48
|
+
]
|
|
49
|
+
}
|
|
50
|
+
}
|