summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorOmar Rizwan <omar@omar.website>2023-04-15 04:24:53 +0000
committerOmar Rizwan <omar@omar.website>2023-04-15 04:24:53 +0000
commitf55f71ab5bd1dd14a8a10fc6c014150e4a0bc5bc (patch)
tree7988df0333eb3e2a004945bab8d1dd0c0a155a6f /lib
parentVendor nanopb (diff)
downloadfolk-f55f71ab5bd1dd14a8a10fc6c014150e4a0bc5bc.tar.gz
folk-f55f71ab5bd1dd14a8a10fc6c014150e4a0bc5bc.zip
c: Support quotation mark includes
Diffstat (limited to 'lib')
-rw-r--r--lib/c.tcl6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/c.tcl b/lib/c.tcl
index 8b9ed792..81819606 100644
--- a/lib/c.tcl
+++ b/lib/c.tcl
@@ -151,7 +151,11 @@ namespace eval c {
::proc include {h} {
variable code
- lappend code "#include $h"
+ if {[string index $h 0] eq "<"} {
+ lappend code "#include $h"
+ } else {
+ lappend code "#include \"$h\""
+ }
}
::proc linedirective {} {
set frame [info frame -2]