6 ms·
What do you mean "the type of strings"? In pretty much every programming language, String is one of the most fundamental types. There's no "different types of s
by bedobi 3y ago
What do you mean "the type of strings"? In pretty much every programming language, String is one of the most fundamental types. There's no "different types of string".
(yes, this is a joke, a bad one at that. badum tish)
- justinclift 3y agoMeh, "text" is where it's at. "varchar()" is so Oracle. :p
- selcuka 3y agoObviously you haven't seen the Substring [1] type of Swift. [1] https://developer.apple.com/documentation/swift/substring https://developer.apple.com/documentation/swift/substring
- gabereiser 3y agoBut this is a slice. So technically a []char?
- selcuka 3y agoNot really. It's only a reference to the original string, a start index, and an end index. It doesn't store a second (partial) copy of the string.
- agent281 3y agoIn some languages it's two or more of the fundamental types. Obviously you haven't been using the big brained languages like Rust, Haskell, or Elixir. (Also a bad joke.)
- sgtnoodle 3y agoWhen I worked at Google, they had their own string type in place of std::string for various reasons. Python has byte strings, Unicode strings, format strings, regular expression strings, and probably a few others! Rust has str and String, depending on ownership.
- lakomen 3y ago> Rust has str and String, depending on ownership. Why I hate Rust
- sgtnoodle 3y agoC++ has string and string_view. Python has memoryview. It seems like a necessary evil if you don't want folk working in raw pointers?
- bedobi 3y agohonestly the difference between basic types like String in different contexts in different languages and dbs is enough to give me ptsd lol
- gabereiser 3y agothere's String, string, std::string, and the satanic *char. Just like there's Slinky, Super Slinky, Extra Slinky, Heavy, and Pro. Nickel-wound (ref counted), steel wound (raw array), and classical nylon (a fucking pointer).
- SAI_Peregrinus 3y agoWhat are gut strings then? Indexed addressing?
- gabereiser 3y agolol, those would be raw pointers as well but at the asm level with registers. Joking aside, gut strings are extremely rare outside professionals. I’m not surprised to see it mentioned with this crowd. Cheers for tickling this music nerds interests.