[Vala] string starts_with



Hi,

I am wondering if there is some kind of string.starts_with method in
vala. 
I try to avoid a memory-allocating algorithm like 

        if ("Hello World"[0:5] == "Hello")

but do not know how to implement this without a starts_with method.
Are there any plans to implement it. I found such a method in the string
class at
http://gitorious.org/dova/dova-core/blobs/master/src/string.vala
but my valac 0.11.5 still does not know such a method.

Regards
juergen





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]