Compare commits
8 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
73e9da8435 | ||
![]() |
bf23337923 | ||
![]() |
02bd3bf69d | ||
![]() |
82a3417b97 | ||
![]() |
1f986c3732 | ||
![]() |
20e998fd12 | ||
![]() |
0f9c0d1e97 | ||
![]() |
2ae13d534e |
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
/bin
|
@@ -22,6 +22,6 @@ env:
|
|||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
provider: script
|
provider: script
|
||||||
script: haxelib run travix release
|
script: haxe && haxelib run travix release
|
||||||
on:
|
on:
|
||||||
tags: true
|
tags: true
|
5
.vscode/settings.json
vendored
Normal file
5
.vscode/settings.json
vendored
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
"haxe.displayConfigurations": [
|
||||||
|
["tests.hxml"]
|
||||||
|
]
|
||||||
|
}
|
6
.vscode/tasks.json
vendored
Normal file
6
.vscode/tasks.json
vendored
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
"version": "0.1.0",
|
||||||
|
"command": "haxelib",
|
||||||
|
"args": ["run", "travix", "node"],
|
||||||
|
"problemMatcher": "$haxe"
|
||||||
|
}
|
1
bin/.gitignore
vendored
1
bin/.gitignore
vendored
@@ -1 +0,0 @@
|
|||||||
*.n
|
|
@@ -11,8 +11,8 @@
|
|||||||
"contributors": [
|
"contributors": [
|
||||||
"back2dos"
|
"back2dos"
|
||||||
],
|
],
|
||||||
"releasenote": "Alias for TypeMap",
|
"releasenote": "Added Types.getMeta",
|
||||||
"version": "0.13.2",
|
"version": "0.13.4",
|
||||||
"url": "http://haxetink.org/tink_macro",
|
"url": "http://haxetink.org/tink_macro",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"tink_core": ""
|
"tink_core": ""
|
||||||
|
@@ -49,6 +49,16 @@ class Types {
|
|||||||
throw 'not implemented';
|
throw 'not implemented';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static public function getMeta(type:Type)
|
||||||
|
return switch type {
|
||||||
|
case TInst(_.get().meta => m, _): [m];
|
||||||
|
case TEnum(_.get().meta => m, _): [m];
|
||||||
|
case TAbstract(_.get().meta => m, _): [m];
|
||||||
|
case TType(_.get() => t, _): [t.meta].concat(getMeta(t.type));
|
||||||
|
case TLazy(f): getMeta(f());
|
||||||
|
default: [];
|
||||||
|
}
|
||||||
|
|
||||||
static function getDeclaredFields(t:ClassType, out:Array<ClassField>, marker:Map<String,Bool>) {
|
static function getDeclaredFields(t:ClassType, out:Array<ClassField>, marker:Map<String,Bool>) {
|
||||||
for (field in t.fields.get())
|
for (field in t.fields.get())
|
||||||
if (!marker.exists(field.name)) {
|
if (!marker.exists(field.name)) {
|
||||||
|
Reference in New Issue
Block a user