comparison modules/string.tp @ 270:b74956a2196f

Add a propertiesOf method to the object module that returns the names of things that look like getter messages
author Michael Pavone <pavone@retrodev.com>
date Fri, 18 Jul 2014 20:45:50 -0700
parents d2b70cba661e
children bb4723fec05e
comparison
equal deleted inserted replaced
269:632667d95d35 270:b74956a2196f
302 end <- end + 1 302 end <- end + 1
303 } 303 }
304 from: start withLength: (end - start) 304 from: start withLength: (end - start)
305 } 305 }
306 306
307 endsWith? <- :suffix {
308 if: (suffix length) <= length {
309 0 = (compareSub: suffix (length - (suffix length)) 0 (suffix length))
310 }
311 }
312
307 isInteger? <- { false } 313 isInteger? <- { false }
308 isString? <- { true } 314 isString? <- { true }
309 isBasicString? <- { true } 315 isBasicString? <- { true }
310 } 316 }