Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

first shot at re-adding 't' to nci thunk gen; also needs tests and re…

…view
  • Loading branch information...
commit 7ac893d43469b474c14b80734ddb88deed8ecb2f 1 parent f73c1c5
@cotto cotto authored
Showing with 10 additions and 1 deletion.
  1. +10 −1 tools/dev/nci_thunk_gen.pir
View
11 tools/dev/nci_thunk_gen.pir
@@ -877,7 +877,7 @@ ERROR
(empty_line_regex, pcre_errstr, pcre_errint) = pcre_comp($S0, pcre_extended)
if pcre_errint goto pcre_comp_err
- $S0 = "^ [[:space:]]* ( (?: [INSPcsilfdpv] [[:space:]]* )+ ) (?: [#] .* )? $"
+ $S0 = "^ [[:space:]]* ( (?: [INSPcsilfdptv] [[:space:]]* )+ ) (?: [#] .* )? $"
(old_style_sig_line_regex, pcre_errstr, pcre_errint) = pcre_comp($S0, pcre_extended)
if pcre_errint goto pcre_comp_err
@@ -987,6 +987,15 @@ REGEX
JSON
table[.DATATYPE_PTR] = $P1
+ $P1 = 'from_json'(<<'JSON')
+{ "c_type": "char *",
+ "pcc_type": "STRING *",
+ "preamble_tmpl": "v_%i = STRING_IS_NULL(t_%i) ? '' : Parrot_str_get_tied_cstring(interp, t_%i);",
+ "sig_char": "t"
+ }
+JSON
+ table[.DATATYPE_CSTR] = $P1
+
$P1 = 'from_json'('{ "c_type": "char", "sig_char": "I", "pcc_type": "INTVAL" }')
table[.DATATYPE_CHAR] = $P1
Please sign in to comment.
Something went wrong with that request. Please try again.