|
Bongo Bill posted:There are even fewer men in computers than women because men are larger. Men in computers tend to be even larger than average. Makes you think.
|
# ? Apr 10, 2014 14:21 |
|
|
# ? May 27, 2024 23:28 |
|
Exactly, this is what I'm talking about. Look at those ladies perform system maintenance
|
# ? Apr 10, 2014 14:21 |
|
"Why don't you come down and mount my disk- no, really- I mean mount my disk. I need those files."
|
# ? Apr 10, 2014 14:33 |
|
C code:
|
# ? Apr 10, 2014 14:54 |
|
omeg posted:
just to check I understood, is the issue here that they put "u" at the start of the variable names but they're signed integers?
|
# ? Apr 10, 2014 14:56 |
|
omeg posted:
Part of the AT&T uVerse codebase?
|
# ? Apr 10, 2014 15:06 |
|
Hammerite posted:just to check I understood, is the issue here that they put "u" at the start of the variable names but they're signed integers? Yeah. I hate that poo poo. If you insist on using that awful notation at least keep it up to date.
|
# ? Apr 10, 2014 15:07 |
|
|
# ? Apr 10, 2014 15:36 |
|
I'm a coding horror. Ive been working on my personal site/blog/portfolio thing and just couldnt get the loving flask-babel translations to work. They worked fine locally, but on the host only default language worked. After few days and some test apps, i was about to change my career to a bum, ive randomly decided to look at the files on the server. Compiled translation map or whatever that is, was missing. Since its compiled, ive ignored it in git. Turns out this isnt that great when your deployment consist of `git pull`.
|
# ? Apr 10, 2014 15:56 |
|
Sulla-Marius 88 posted:Just so I haven't misinterpreted this, you're referring to the overwhelming number of socially-maladjusted sexist IT workers who for some reason can't keep their worthless opinions to themselves, right? Rather than criticising 'radical feminists' yourself.. Pretty sure he actually thinks that those of us who understand that what MRAs would call 'biotruths' are just artifacts of a misogynistic patriarchy are actually misandrists and possibly gender traitors (for those of us who are male). Holy poo poo - misogyny is in Opera's built-in dictionary but not misandry. Radical Feminism at work!
|
# ? Apr 10, 2014 16:00 |
Munkeymon posted:Pretty sure he actually thinks that those of us who understand that what MRAs would call 'biotruths' are just artifacts of a misogynistic patriarchy are actually misandrists and possibly gender traitors (for those of us who are male). It's not men's fault if women make the decision not to embark on an IT career. The options are equal and fair, and having been through a fulfilling IT education myself, I see no reason to change it now. That would be like cancelling the Big Bang Theory because Penny's skirt was too short and offended the tumblr social justice brigade.
|
|
# ? Apr 10, 2014 16:15 |
|
Munkeymon posted:Pretty sure he actually thinks that those of us who understand that what MRAs would call 'biotruths' are just artifacts of a misogynistic patriarchy are actually misandrists and possibly gender traitors (for those of us who are male). That's just what the coding horrors thread needed, another derail whereupon idiot IT workers in the bad code catharsis thread discuss critical gender theory while jerkin their gherkins into their fedoras. At least put some comedy into your shitposting if you're determined to turn every subforum into LF-prime. Juventus stultorum magister: A CODING HORROR: code:
A CODING HORROR: code:
In short, suck the fattest part of my rear end in a top hat!
|
# ? Apr 10, 2014 16:24 |
|
Oh man, Otto, you reminded me of that Leah Culver thing and that's just rude.
|
# ? Apr 10, 2014 16:26 |
|
Has anyone worked with formally verifying code? Is it really that difficult to prove correctness for programs? With all the Heartbleed craziness it seems weird that critical crypto code that millions of users and billions of dollars rely on could be so badly written. Is it intractable to write a formally proven TLS library in C, or is mathematical correctness just not a high priority?
|
# ? Apr 10, 2014 16:31 |
|
tractor fanatic posted:Is it really that difficult to prove correctness for programs? quote:Is it intractable to write a formally proven TLS library in C, or is mathematical correctness just not a high priority? e: Or rather, writing buggy software and dealing with the consequences is so cheap that no-one sees the point in paying for correct software. See also: various proposals for licensing software engineers.
|
# ? Apr 10, 2014 16:36 |
|
tractor fanatic posted:Has anyone worked with formally verifying code? Is it really that difficult to prove correctness for programs? With all the Heartbleed craziness it seems weird that critical crypto code that millions of users and billions of dollars rely on could be so badly written. Is it intractable to write a formally proven TLS library in C, or is mathematical correctness just not a high priority? Yes, proving correctness is very hard, especially when you are trying to prove correctness of a program written in a real programming language and not a convenient subset of one. But there are a lot of static analysis techniques that are practical and can fix those types of bugs.
|
# ? Apr 10, 2014 16:36 |
|
The sketchiest if that I have ever seen:code:
|
# ? Apr 10, 2014 16:41 |
|
ASI is not some scary thing where the compiler will randomly inserts semicolons into your code. People just make it out to be bigger than it actually is. I only bring up return for #1 because that's the only time I could see that rule ever applying. Where you decide to return an object and place the curly brace on the next line rather than next to the return. Because for all those other statements it makes no sense. Who writes a throw on two lines? If some beginner is writing a throw on two lines, there's bigger problems than the ASI. And when's the last time you actually had to apply an identifier to a break/continue? Then put it on a separate line? If you are someone who writes a lot of javascript code you should be aware of these rules anyways and realize 0% chance you'll run into them. pokeyman posted:I write my C and C++ using trigraphs whenever possible. The rules aren't complicated, it's a simple step before preprocessing. I mean, just memorize this brief table: OK, weird strawman argument to bring in. shrughes posted:I think optional semicolons are great because when you see somebody that thinks it makes sense to omit them or that semicolons are ugly, you'll be ready for superficialities in other opinions they hold, be it on encodings, design patterns, how to use version control systems, or radical feminism.
|
# ? Apr 10, 2014 16:58 |
|
tractor fanatic posted:Has anyone worked with formally verifying code? Is it really that difficult to prove correctness for programs? With all the Heartbleed craziness it seems weird that critical crypto code that millions of users and billions of dollars rely on could be so badly written. Is it intractable to write a formally proven TLS library in C, or is mathematical correctness just not a high priority? Heartbleed's bug isn't cryptographic, really. It'd have the same impact if it were in the HTTP server or whatever else that's widely deployed. There's been a lot of work done on model checking of crypto protocols (and that work has found real SSL problems, IIRC), but the gap between "model as specified" and "code as typed" is pretty big, especially when running in the same address space as other programs. AFAIK model extractors that work from the actual C source don't currently handle pointer algebra, so they would choke to death immediately on OpenSSL. (Or basically any other industrial C system.) My layman's understanding is that the kernel of things that can be effectively verified is growing at a decent rate, but there is still a long way to go until it can verify important properties when there are libcs and kernels and whatever else in the mix, even once the models expand to cover all of the intricate TLS specification. https://alfredo.pironti.eu/research/sites/default/files/cf11.pdf has a pretty good summary of recent state of the art, IMO. And of course, you get brilliant decisions like this one: http://article.gmane.org/gmane.os.openbsd.misc/211963 Theo de Raadt posted:
Another question might be "why write critical code in C?" The people who care about verified properties pretty much don't.
|
# ? Apr 10, 2014 16:59 |
|
Strong Sauce posted:Who writes a throw on two lines? If some beginner is writing a throw on two lines, there's bigger problems than the ASI. The code not doing what it looks like it ought to do, but following some crazy moon logic instead, is a bigger problem than someone making an idiosyncratic formatting choice?
|
# ? Apr 10, 2014 17:09 |
|
Meanwhile people unironically dismiss Ada as a viable systems programming option because
|
# ? Apr 10, 2014 17:09 |
|
While it seems like we are back on track, we will definitely not be continuing any derails regarding people's lovely opinions about feminism. As a reminder, if someone makes a post that you feel is an obvious troll or derail bait, report it and do not reply.
|
# ? Apr 10, 2014 17:33 |
|
Strong Sauce posted:I only bring up return for #1 because that's the only time I could see that rule ever applying. Where you decide to return an object and place the curly brace on the next line rather than next to the return. Because for all those other statements it makes no sense. Who writes a throw on two lines? If some beginner is writing a throw on two lines, there's bigger problems than the ASI. And when's the last time you actually had to apply an identifier to a break/continue? Then put it on a separate line? People throw and yield objects as well as returning them. Why is that less reasonable than returning one? I guess you could have an "only throw primitives" house rule. My reason for bringing up the additional cases is that "just understand it" seems like pretty facile advice, and it's not the cases that happen every day that cause problems. It's the unusual edges that you bump into where using the more consistent syntactic pattern helps you, because there are fewer "these 5 constructs are special" rules to keep in mind when minifying/transpiling/gluing together/refactoring/generating code/whatever. Doug Crockford and @fat collided this way in the jsmin/bootstrap thing, and whatever one might say about either's technical tastes, there is no lack of expertise. The issue there isn't that the JS parser does magic with ASI and [nlth], it's that every other tool (including humans) has to correctly deal with a more complex grammar. Internet Janitor posted:Meanwhile people unironically dismiss Ada as a viable systems programming option because Also, because it requires semicolons.
|
# ? Apr 10, 2014 17:38 |
|
Internet Janitor posted:Meanwhile people unironically dismiss Ada as a viable systems programming option because Give it up, ADA is never going to be a thing outside the defence industry. Even there it's loosing ground: https://en.wikipedia.org/wiki/Lockheed_Martin_F-35_Lightning_II
|
# ? Apr 10, 2014 17:47 |
|
Strong Sauce posted:ASI is not some scary thing where the compiler will randomly inserts semicolons into your code. People just make it out to be bigger than it actually is. Just use the goddamned semicolons.
|
# ? Apr 10, 2014 17:54 |
|
I had to look into an issue with a deploy that went out a week ago that caused our GC time to increase ~400% (why no one caught it at release is another story). After digging around for a bit, I found a change to a view partial for country selection for targeting purposes. Originally the partial was a select list of countries, nothing crazy. The updated version added a hierarchy of Continents, Countries and Regions (States or Providences), which doesn't sound to crazy except it ends up generating ~4,000 lines every time the partial is rendered (which is on every form related to targeting, or almost all of our forms). After some profiling my theory was confirmed: the original partial had at most 1 GC invocation per 10 runs; the updated partial invoked GC at least 3 times for every render. Not to mention every render sorts every "region" for every country without caching the sorted region list. Oh, and render times went from ~60ms to over 1 second. I'm still pretty upset this change got in, we're generally pretty good about keeping such horible performance hits out of our codebase (or at least mitigated through aggressive caching / client-side rendering)
|
# ? Apr 10, 2014 19:16 |
|
necrotic posted:I had to look into an issue with a deploy that went out a week ago that caused our GC time to increase ~400% (why no one caught it at release is another story). After digging around for a bit, I found a change to a view partial for country selection for targeting purposes. Originally the partial was a select list of countries, nothing crazy. The updated version added a hierarchy of Continents, Countries and Regions (States or Providences), which doesn't sound to crazy except it ends up generating ~4,000 lines every time the partial is rendered (which is on every form related to targeting, or almost all of our forms). This sounds so much like it could have happened in a company I used to work for. Well apart from the bit about the aggressive caching making the site faster, where I worked aggressive caching tended to make it slower.
|
# ? Apr 10, 2014 19:27 |
|
This works as expected:C# code:
C# code:
e: My original version used "true" in the first snippet but "false" in the second, but that was a brain fart. raminasi fucked around with this message at 19:40 on Apr 10, 2014 |
# ? Apr 10, 2014 19:30 |
|
Zombywuf posted:This sounds so much like it could have happened in a company I used to work for. Well apart from the bit about the aggressive caching making the site faster, where I worked aggressive caching tended to make it slower. I... how? Is the cache stored on a floppy through a ethernet connection measured in baud?
|
# ? Apr 10, 2014 19:32 |
|
GrumpyDoctor posted:This works as expected: Is SomeProperty true for foo or for customFooCollection[someIndex]?
|
# ? Apr 10, 2014 19:34 |
|
GrumpyDoctor posted:This works as expected: That seems weird. Are you sure that the behavior isn't like this (which is dumb beyond belief, don't get me wrong): code:
|
# ? Apr 10, 2014 19:38 |
|
Zombywuf posted:Give it up, ADA is never going to be a thing outside the defence industry. Even there it's loosing ground: https://en.wikipedia.org/wiki/Lockheed_Martin_F-35_Lightning_II Ada is not an acronym...
|
# ? Apr 10, 2014 19:39 |
|
tractor fanatic posted:Is SomeProperty true for foo or for customFooCollection[someIndex]? Well I assumed that they'd be the same, but what I think is happening based on my tea-leaf readings of other parts of the documentation is that the collection's indexer is actually kicking out a clone, and in the original, the property is read-only, but doesn't throw or anything when you try write to it. Most of this documentation is only "documentation" in the sense that Sandcastle created it, but it's not giving me any more information than just using Intellisense. Ithaqua posted:That seems weird. Are you sure that the behavior isn't like this (which is dumb beyond belief, don't get me wrong): I have clarified my example.
|
# ? Apr 10, 2014 19:44 |
|
GrumpyDoctor posted:Well I assumed that they'd be the same, but what I think is happening based on my tea-leaf readings of other parts of the documentation is that the collection's indexer is actually kicking out a clone, and in the original, the property is read-only, but doesn't throw or anything when you try write to it. Most of this documentation is only "documentation" in the sense that Sandcastle created it, but it's not giving me any more information than just using Intellisense. Looks like you're using a struct (value type) as the type stored in customFooCollection. You'll need to get an item out, change it, and then put it back into the dictionary to get that working correctly.
|
# ? Apr 10, 2014 19:48 |
|
Internet Janitor posted:Meanwhile people unironically dismiss Ada as a viable systems programming option because Ada isn't the language that either compiles and runs or, if you have any error, says 'No' without any explanation, right? I'd really like to clear that up if I have it wrong.
|
# ? Apr 10, 2014 20:06 |
|
Munkeymon posted:Ada isn't the language that either compiles and runs or, if you have any error, says 'No' without any explanation, right? I'd really like to clear that up if I have it wrong. That's not a language thing, that's a 'my compiler is poo poo at reporting errors' thing. The language in no way mandates bad error reporting.
|
# ? Apr 10, 2014 20:18 |
|
ninjeff posted:Looks like you're using a struct (value type) as the type stored in customFooCollection. You'll need to get an item out, change it, and then put it back into the dictionary to get that working correctly. The contained type is a reference type; if it were a value type, this wouldn't have compiled.
|
# ? Apr 10, 2014 20:19 |
|
feedmegin posted:That's not a language thing, that's a 'my compiler is poo poo at reporting errors' thing. The language in no way mandates bad error reporting. no. he's talking about prolog
|
# ? Apr 10, 2014 20:20 |
|
necrotic posted:I... how? Is the cache stored on a floppy through a ethernet connection measured in baud? I've encountered a lot of caches that don't actually make anything faster. Common reasons include terrible cache implementations that take as long to look up things as looking them up in the database, caching things that take less time to compute from scratch each time than to cache, the cache getting invalidated too frequently to be of any real use, having to spend enough time ensuring the cache gets invalidated when needed that it ends up outweighing the speed gains, bad LRU implementations that slow down as the cache gets bigger and so appear great in tiny benchmarks but suck in real usage, and just plain never actually reading stuff from the cache. A cache making things slower is of course still far better than the more common failure case of stale things being read from the cache. I tend to get twitchy when people propose Just Cache It.
|
# ? Apr 10, 2014 20:23 |
|
|
# ? May 27, 2024 23:28 |
|
Munkeymon:code:
code:
Ada isn't anything really weird or exotic- it's basically a beefed-up version of Pascal.
|
# ? Apr 10, 2014 21:15 |