-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcompile-only-question.fs
More file actions
42 lines (31 loc) · 1.01 KB
/
compile-only-question.fs
File metadata and controls
42 lines (31 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
\ galope/compile-only-question.fs
\ This file is part of Galope
\ http://programandala.net/en.program.galope.html
\ Author: Marcos Cruz (programanda.net), 2017.
\ ==============================================================
[undefined] compile-only? [if]
\ Gforth<0.7.9
require ./name-to-flags.fs
: compile-only? ( nt -- f )
name>flags @ restrict-mask and 0<> ;
\ doc{
\
\ compile-only? ( nt -- f )
\
\ _f_ is true if the word _nt_ is compile-only (ie. restrict).
\
\ NOTE: The _nt_ of a compile-only word _name_ can not be obtained
\ by `' _name_ >name`, because `'` performs `-14 throw` if _name_
\ has no interpretation semantics. `comp' _name_ drop >name` can be
\ used instead, or simply `(') _name_`.
\
\ NOTE: ``compile-only?`` is included in Gforth 0.7.9. If
\ ``compile-only?`` is defined already, this module does nothing.
\
\ See: `immediate?`, `name>flags`.
\
\ }doc
[then]
\ ==============================================================
\ Change log
\ 2017-11-15: Start.