• R/O
  • SSH

kink: Commit

Kink runtime


Commit MetaInfo

Revisiona4153abd001b81a28a8b426fa45391735a6d5478 (tree)
Time2020-02-10 23:19:02
Authormiyakawataku
Commitermiyakawataku

Log Message

rename SECTION.section?? to SECTION.is?

Change Summary

Incremental Difference

diff -r 1ff17c624932 -r a4153abd001b src/main/resources/kink-mods/kink/doc/model/SECTION.kn
--- a/src/main/resources/kink-mods/kink/doc/model/SECTION.kn Mon Feb 10 23:10:01 2020 +0900
+++ b/src/main/resources/kink-mods/kink/doc/model/SECTION.kn Mon Feb 10 23:19:02 2020 +0900
@@ -39,7 +39,7 @@
3939 .format(Desc Title_req Title.repr))
4040 VEC.is?(Blocks) && Blocks.for_all?(BLOCK$is?) || raise(
4141 '{}: required vec of blocks for Blocks, but got {}'.format(Desc Blocks.repr))
42- VEC.is?(Subsections) && Subsections.for_all?($section?) || raise(
42+ VEC.is?(Subsections) && Subsections.for_all?($is?) || raise(
4343 '{}: required vec of sections for Subsections, but got {}'.format(Desc Subsections.repr))
4444
4545 new_val(
@@ -57,10 +57,10 @@
5757 Title_regex.accept?(Title)
5858 }
5959
60-## SECTION.section?(Val)
60+## SECTION.is?(Val)
6161 #
62-# section? returns whether Val is a section.
63-:section? <- {(:Val)
62+# SECTION.is? returns whether Val is a section.
63+:is? <- {(:Val)
6464 Val.var_syms.have_all?(Section_var_syms)
6565 }
6666
diff -r 1ff17c624932 -r a4153abd001b src/test/kink/doc/model/SECTION_test.kn
--- a/src/test/kink/doc/model/SECTION_test.kn Mon Feb 10 23:10:01 2020 +0900
+++ b/src/test/kink/doc/model/SECTION_test.kn Mon Feb 10 23:19:02 2020 +0900
@@ -93,18 +93,18 @@
9393 }
9494
9595 # }}}1
96-TEST.group('.section?'){ # {{{1
96+TEST.group('.is?'){ # {{{1
9797 TEST.test('returns true for section'){
9898 :Sect = SECTION.new(
9999 'Odyssey'
100100 [BLOCK.new_paragraph('hey ho') BLOCK.new_code("foo()\n")]
101101 []
102102 )
103- SECTION.section?(Sect) || raise('got false')
103+ SECTION.is?(Sect) || raise('got false')
104104 }
105105
106106 TEST.test('returns false for nada'){
107- SECTION.section?(nada) && raise('got true')
107+ SECTION.is?(nada) && raise('got true')
108108 }
109109 }
110110
Show on old repository browser