|
Malcolm XML posted:Also Unicode is basically institutionally racist zawgyi in unicode
|
# ? Nov 26, 2017 18:25 |
|
|
# ? May 22, 2024 06:48 |
|
ComradeCosmobot posted:let us tell u about something called combining characters reminder that these were in unicode 1.0 the one that had to be a fixed width encoding the one that meant han unification had to happen unicode!
|
# ? Nov 26, 2017 18:27 |
|
MononcQc posted:IMO python3 suffered a whole lot because as far as I understand 1. they took away byte strings at first so everyone would be forced to use unicode when it made no sense (they just flipped the bad decision around) 2. it took a long while to bring back 3. everyone had to learn the conceptual difference between byte strings and unicode at once. 1. kinda 'we're going to swap str and unicode around' 'then we're going to change the interface of bytestrings' 'and then remove format strings' 2. yep that and foward compatibility wasn't really on the table 3. no it's more what suspicious dish said, a lot of byte janitors used python2 instead of perl or ruby python3 threw away str and introduced bytes, and they don't work the same at a fundamental level
|
# ? Nov 26, 2017 18:32 |
|
dynamic typing and dealing with different semantic ideas of string is a recipe for failure
|
# ? Nov 26, 2017 18:41 |
|
are swift and rust the only 'mainstream' langs that don't guide you into doing the wrong thing by letting you idiomatically index or enumerate by codepoint on unicode strings
|
# ? Nov 26, 2017 18:42 |
|
I hear Perl 6 is pretty good on that score. E: Oh wait, you said "mainstream".
|
# ? Nov 26, 2017 19:15 |
|
note that, pertinently to the bytes/characters debate, swift also sees strings as basically a view over the raw code-unit sequence. so if you have terrible malformed utf-8 string data, it will present as containing invalid characters (\uFFFD); but if you ask it for a utf-8 view, it hasn't actually thrown any of that information away, whereas my impression is that python actually normalizes the string data implicitly when it discovers invalid encodings
|
# ? Nov 26, 2017 20:20 |
|
What do you languages people think of pythons type annotations + mypy? Personally, I get much usage out of the type annotations just because it makes PyCharm that much better, but I'm just interested in reading some opinions about the whole idea.
|
# ? Nov 26, 2017 20:32 |
Thermopyle posted:What do you languages people think of pythons type annotations + mypy? i like them. code readability is more or less the same imo, the only thing that is awkward is specifying dual output types (<datatype>, NoneType) but you just do that with Union(). i kinda wish you could optionally "flip" the interpreter to just block script execution if a blatant type mismatch is detected somewhere granted, i have not used mypy specifically, since pycharm has its own solution that just integrates with py3 type annotations. more broadly, im not even sure whats the functionality venn diagram on py3 core+pycharm vs mypy looks like
|
|
# ? Nov 26, 2017 20:38 |
|
I really love that python 3 invented a whole syntax for type annotations without ever testing it or giving it semantics so it's basically useless
|
# ? Nov 26, 2017 20:41 |
|
Suspicious Dish posted:I really love that python 3 invented a whole syntax for type annotations without ever testing it or giving it semantics so it's basically useless u are very salty about python 3!
|
# ? Nov 26, 2017 20:47 |
|
but yes, the whole "here you can annotate your types but no we dont do anything with that information" thing is weird
|
# ? Nov 26, 2017 20:49 |
Thermopyle posted:but yes, the whole "here you can annotate your types but no we dont do anything with that information" thing is weird that has me wondering if it is an attempted bone for static typing crowd, or do they have further plans?
|
|
# ? Nov 26, 2017 20:51 |
|
Thermopyle posted:u are very salty about python 3! I'm not actually that angry at all I just think it's a shame and it's hilarious what kinds of stuff they're doing to their dying plang
|
# ? Nov 26, 2017 20:52 |
|
cinci zoo sniper posted:that has me wondering if it is an attempted bone for static typing crowd, or do they have further plans? mypy Guido is big on mypy he discovers plang features 25 years after everyone else
|
# ? Nov 26, 2017 20:57 |
Malcolm XML posted:mypy at least we didnt get rob pike i guess
|
|
# ? Nov 26, 2017 20:59 |
|
cinci zoo sniper posted:that has me wondering if it is an attempted bone for static typing crowd, or do they have further plans? i assumed it was based on the same kind of petulant fake compromise wherein guido removed reduce from the functions in the default namespace on the basis that the only things he could possibly imagine using it for were calculating the sum or product of an array "well gosh everybody makes a huge deal about how they like static types; i don't even get why you'd want them. fine here have annotations. what are the semantics? dunno, whatever the reference interpreter does. anyway now that's settled once and for all."
|
# ? Nov 26, 2017 21:08 |
|
Internet Janitor posted:i assumed it was based on the same kind of petulant fake compromise wherein guido removed reduce from the functions in the default namespace on the basis that the only things he could possibly imagine using it for were calculating the sum or product of an array that was some dumb poo poo
|
# ? Nov 26, 2017 21:16 |
|
Internet Janitor posted:i assumed it was based on the same kind of petulant fake compromise wherein guido removed reduce from the functions in the default namespace on the basis that the only things he could possibly imagine using it for were calculating the sum or product of an array i think theres more to it than that...guido is heavily involved in mypy and dropbox (with guido) just open sourced pyannotate for automated type annotations on legacy code bases guido is doing a lot of types stuff whether that means anything for core python remains to be seen
|
# ? Nov 26, 2017 21:16 |
guido posted:So now reduce(). This is actually the one I've always hated most, because, apart from a few examples involving + or *, almost every time I see a reduce() call with a non-trivial function argument, I need to grab pen and paper to diagram what's actually being fed into that function before I understand what the reduce() is supposed to do. So in my mind, the applicability of reduce() is pretty much limited to associative operators, and in all other cases it's better to write out the accumulation loop explicitly.
|
|
# ? Nov 26, 2017 21:20 |
|
Thermopyle posted:i think theres more to it than that...guido is heavily involved in mypy and dropbox (with guido) just open sourced pyannotate for automated type annotations on legacy code bases basically Guido actually went to a company that has to use Python in real production apps and discovered that typing has a use
|
# ? Nov 26, 2017 21:20 |
|
if it results in a gradual type system like typescript hell yeah
|
# ? Nov 26, 2017 21:21 |
|
Malcolm XML posted:if it results in a gradual type system like typescript hell yeah thats basically what you get now with mypy
|
# ? Nov 26, 2017 21:25 |
ok im looking at mypy and pretending to think atm and yeah the man himself ("bdfl" ) is posting on issues. did he leave google for this to work with dropbox or something? time to understand where mypy stands vs pycharm internals and whats a better option
|
|
# ? Nov 26, 2017 21:25 |
|
typescript has more features that i often find myself wishing for in python/mypy/pycharm like string literal types cinci zoo sniper posted:ok im looking at mypy and pretending to think atm and yeah the man himself ("bdfl" ) is posting on issues. did he leave google for this to work with dropbox or something? guido just works a lot with jukka on mypy...probably because like malcolm xml said he all of a sudden realized that types were helpful when he had to work on a big codebase...dropbox's python lines of code is in the millions. guido has worked at dropbox for several years.
|
# ? Nov 26, 2017 21:29 |
|
type annotations in python 3 are a neat idea, but i don't feel that they integrate well enough with the rest of the system that they're worth much. like, everything else is duck typed, but the type annotations want everything to be nominally typed, where i think Typescript does a better job at making the types useful. also since idents in annotations are evaluated like anything else you can't annotate a class inside itself, you have to use a string, which is workable but makes everything look a bit stupid
|
# ? Nov 26, 2017 22:40 |
|
Thermopyle posted:thats basically what you get now with mypy its not as good because it has guido attempting to half-rear end it instead of having a rad dude like anders heijlsberg behind it
|
# ? Nov 26, 2017 22:42 |
|
as always microsoft gets language design correct and fucks up the execution
|
# ? Nov 26, 2017 22:43 |
|
except typescript actually owns mega hard and anyone writing regular javascript should switch
|
# ? Nov 26, 2017 22:43 |
|
Powaqoatse posted:hows it do if you copy to another application? just wondering whats going on in the frontend on a real operating system with a text rendering and editing infrastructure that’s used by all applications, it just works
|
# ? Nov 26, 2017 23:21 |
|
Suspicious Dish posted:I'm not actually that angry at all I just think it's a shame and it's hilarious what kinds of stuff they're doing to their dying plang is this a weird trumpism or are you genuinely unaware that python is the fastest growing language in the world?
|
# ? Nov 26, 2017 23:27 |
|
Malcolm XML posted:as always microsoft gets language design correct and fucks up the execution What language are you talking about? From context I'm guessing C#, but if so the "fucks up the execution" part doesn't make sense.
|
# ? Nov 26, 2017 23:29 |
|
Malcolm XML posted:its not as good because it has guido attempting to half-rear end it instead of having a rad dude like anders heijlsberg behind it Yeah, I don't disagree
|
# ? Nov 26, 2017 23:34 |
|
a witch posted:is this a weird trumpism or are you genuinely unaware that python is the fastest growing language in the world? do you have stats on this? i'd be surprised that wasn't like, javascript at this point.
|
# ? Nov 26, 2017 23:45 |
|
Asymmetrikon posted:do you have stats on this? i'd be surprised that wasn't like, javascript at this point. I’m basing it on this https://stackoverflow.blog/2017/09/06/incredible-growth-python/ even if it’s not strictly number one, the idea that it’s dying is some bizarre projection from a guy who has spent nearly a decade makin bitter posts about python 3 on this forum
|
# ? Nov 26, 2017 23:52 |
|
Most of the people I knew that were building large systems in Python switched to go or rust or JavaScript. Perhaps the growing amount of questions imply that your documentation and language are lovely.
|
# ? Nov 27, 2017 00:37 |
|
eschaton posted:on a real operating system with a text rendering and editing infrastructure that’s used by all applications, it just works I use osx obvs just wondering what ms does
|
# ? Nov 27, 2017 00:40 |
|
Suspicious Dish posted:Most of the people I knew that were building large systems in Python switched to go or rust or JavaScript. i mean, i get it, python got worse for you with python 3, but you're just being petulant here
|
# ? Nov 27, 2017 00:44 |
|
even if I'm a huge cheerleader for python3 (or at least I just think it was a net positive) I agree that the type annotations are kinda dumb and useless.
|
# ? Nov 27, 2017 01:29 |
|
|
# ? May 22, 2024 06:48 |
|
Suspicious Dish posted:Perhaps the growing amount of questions imply that your documentation and language are lovely. what would your hypothesis have been if the number of questions had gone down
|
# ? Nov 27, 2017 01:31 |