« first day (3406 days earlier)      last day (1525 days later) » 

10:01 AM
BEcause this time it's a grid, I can't predict the parent everytime
I'll try this
TextBox textBox = inputElement as TextBox;
            object meuk = textBox.Parent;
            Point relativePoint = visual.TransformToAncestor((System.Windows.Media.Visual)meuk).Transform(new Point(0, 0));
 
your parent may be null if it's templated
in that case you have to use TemplatedParent
 
It worked
@ntohl thank you for the suggestion
 
@ntohl Internal one, might be ubuntu based? might not be? dunno, don't care.
@Neil The new move semantics, rvalue references, std::unique_ptr, std::shared_ptr and other features I'm just learning make resource and memory management much more sane, and standardized.
 
mr5
@DKDhilip welp, that... looks like... over engineered... though.
 
10:15 AM
@mr5 High performance code lol
 
mr5
I've never use stackalloc
 
I use that to avoid heap memory allocation
 
mr5
i..n is substring right?
 
Array range
 
@DKDhilip does it matter tho?
 
10:17 AM
it does sometimes
 
@Wietlol For fun tho
 
@Neil who downgraded it?
*Wuh downgraded it?
 
also... int[4] -> int[input.Length] ?
 
[4] means I needed only 4, not based on input length
 
but if input length is 5...
 
10:20 AM
Nope...there's only 4 " to compare
 
wait... if input has more than 4 quotes
 
This is some sort of optimization, as we don't know how many quotes before hand
 
just use a dynamically sized list?
new List<int>()
 
No, it allocates heap memory
 
does that matter?
 
10:22 AM
It doesn't really matter for case like that, but this is for exercise and fun lol
 
my definition for fun is not "lets make sure that this code breaks on anything other than the test cases"
Jack, shrug
 
¯\_(ツ)_/¯
 
...
This is an example of performance without safety guarantee
 
this is an example of premature optimizations
 
Depend on context lol
I even named it "FunParser"
 
10:27 AM
if you want to have fun with parsers, make one that can do left recursive patterns :D
 
I'm too lazy to code something like that...
 
good morning yall o/
 
o/
 
or make a math parser with shunting yard
 
Have to wait till the time when I decided to make my own compiler lol
 
10:34 AM
I wrote my own code parser... parser
 
code parser parser code parser
 
Why not a code parser parser parser?
 
@RoelvanUden hahaha
 
:parser
goto parser
 
do you even parse
 
10:36 AM
Maybe I have that kind opportunity develop one
Have to implement SQL parser as part of my work
SQL -> Distributed Query Plan
 
well... I wrote my own version of antlr
which is basically a tool that converts a grammar definition to a parser
but... it also needs a parser to parse that grammar
for which, they also have a grammar definition
for which... they also need a parser
with a grammar....
with a parser...
 
Why do you make something like that?
 
you give up
 
lol
 
you make a substitude parser in your code
then you parse the grammar
 
10:39 AM
Just use the existing one lol
 
I wrote my own because antlr wasnt powerful enough
nor any of the other alternatives
 
have you a site to recommend to learn c#?
 
MS academy?
 
Nope...
 
10:42 AM
Read the entire ECMA-334
 
:start
:prison
:policeman
goto prison // do not pass :start, you do not receive $20.000
 
@MwBakker No, I don't mean offiically. I just mean putting out there that it isn't that critical of a virus for the low fatality rate
 
How can we already speak of a fatality rate if the numbers are too vague
First I do not trust numbers in combination with a communistic regime
Second the spread is ongoing but not long enough to determine newly invected cured or deseased I'd say
 
can you write you own email sending service in 3-4 weeks? With templates, queues etc...
like
 
10:48 AM
yes everything is possible
 
19 hours ago, by Wietlol
the code parser tool basically has all antlr features +
- left recursive (and right recursive) patterns,
- inheritance based lexer tokens,
- type based pattern matching,
- priority based pattern lists (with some options of handling recursion)
- and dynamic grammar (the ability to add rules/options to the grammar at runtime)
@Proxy wanna hear a joke?
I did it
in the first 2 weeks of this year in fact
with templates
queues
the only thing I still need to do is to automatically add a tracing image to it so I can update the status of the mail to "read"
 
cool
 
based on the template or non-templated mail that you request to send, it will add a link to open the email in your browser
 
@MwBakker you look at everyone who has survived the virus vs all the ones who are dead and you look at the ratios
there are plenty of people who have survived it that it is reasonable to conclude the fatality rate
 
oh, I also need to make a dashboard to show the mails to our employees... but I guess that is a V2 feature
 
10:51 AM
@Neil who says you need to die within 2 weeks from the infection?
 
@MwBakker you mean to say, maybe you'll die from the virus after 3 years?
possible, but not likely, seeing how many people are recovered
plus I don't think they would take people into consideration that were still sick
 
I finally got approval on the new storage lads
 
fait enough
 
woooot! new storage \o/
wait... storage?
 
No more do I have to sit around for hours waiting for the cluter to boot
 
10:53 AM
what do you use it for?
 
Our hyper-v cluster
 
sounds cool
 
Which for some reason we were told to run on a RAID5 array with 4x 5400RPM drives
 
aka, I have no clue what the heck you are talking about
 
Bunch of spinning rusts?
 
10:53 AM
When I said "we need SSDs"
We used to boot off NVMe SSDs, then we downgraded so hard to that, which we've been running since June
@Wietlol We have a 3 node server cluster which runs a bunch of VMs on it
 
cool
 
With a total of 72 cores and 576GB of ram
 
>64 cores = too many cores
 
we have an nk node server cluster with our entire infrastructure on it
 
It's a cluster it's fine
 
10:56 AM
with a total of ak cores and mtwn GB of ram
 
Also your opinion is wrong because you ahve about a trillion cores
Oh that cluster has our entire server estate on it
Obviously except the nodes that run it
 
@Wietlol It's not nice to exploit north korea like that
 
it stands for "nobody knows"
 
Perks of on-prem
 
Hi everyone, does someone know a little bit about xml serialization?

I have an xml string with generic tag, but in the end, all of them are of the same type.
```
<rootNode>
<el1><name>blub</name></el1>
<el1><name>blub1</name></el1>
<el2><name>blub2</name></el2>
</rootNode>
```

problem is, I have multiple of el1, multiple of el2, no idea what the names of those could be, but in the end all of them share the same data.

Is there a way to serialize this object to a c# Object, containing a List, where all of the child nodes (el1, el2, elN) will be generically serialized to the same object, wi
 
mr5
10:58 AM
"Nobodyknows - Hands Up"
 
Run some crypto miners
 
@Loki is the number of el types known?
or is it just up to infiinity?
like <el9102849017257132847328471239047238904><name>blub2</name></el9102849017257132847328471239047238904>
 
@Wietlol it can be anything, unfortunately. I think I could manually add all those now, but no idea if, in the future, there will be new names
 
I think it would cost something like $4k/mo to run what we have here in azure
 
@Loki you should be serializing a class with all the sub elements pertaining to that instance
 
10:59 AM
(not that 9102849017257132847328471239047238904 is infinity tho)
@CaptainObvious what do you have?
 
That cluster
 
and you shouldn't create a user1 user2 user3 tag
 
With stuff on it
 
if anything you have multiple user elements with an id attribute
but it is also okay to have just lots of user elements with no id attribute
the important thing is to group your data
 
I assume that cluster contains your database, and your web services and your periodic scripts/tools and your caching mechanism and your fallback nodes on disasters
 
11:01 AM
@Wietlol well, currently it's something in between 10 and 23 (maybe all of those) but maybe in the future there will be 24, containing the same data, but the different tag name - I don't want to reprogram the serializer as soon as this happens
 
@Neil I assume Loki has no power on the structure of the xml
 
Whereas the onprem costs us about £150/mo in power and like another maybe £350/mo in amortised hardware costs
 
unfortunately no, no power over the xml
 
I could make one deserializer, but I'm too lazy right now
 
> Is there a way to serialize this object to a c# Object, containing a List, where all of the child nodes (el1, el2, elN) will be generically serialized to the same object, without specifying ElementName="el1" into the XmlArrayItem?
 
11:02 AM
I don't want you to make one for me :) but if there is a way to deserialize generic tags that would be awesome
 
He's serializing it. Clearly he can decide the structure otherwise what are we talking about?
 
if he sends that xml to a third party that only accepts xml in this weird format, then no
 
I get the xml data from an soap endpoint and have to consume it (create c# objects)
 
@Loki perhaps just parse the xml yourself
convert to an XmlDocument or XDocument and scan through the properties creating instances of your models
 
well, the "worst" solution I came up with would be to replace all elx in the string before parsing
 
11:04 AM
that indeed is the worst solution
 
el1 -> el
el2 -> el
....
parse
 
pls dont use the worst solution
 
but you're talking about serializing it..
 
But how frequently your code has to deserialize that XML?
 
if you have to deserialize it first
 
11:05 AM
> convert to an XmlDocument or XDocument and scan through the properties creating instances of your models
just do this
it will be fine
put it in a special class
MyStuffParser
public MyModel Parse(String xmlString)
 
basically I want something like this

[XmlArray(ElementName="arrayRoot")]
[XmlArrayItem(typeof(MyCustomElement))]
public List<MyCustomElement> elements {get;set;}

but without saying

[XmlArray(ElementName="arrayRoot")]
[XmlArrayItem(typeof(MyCustomElement), ElementName="el1")]
[XmlArrayItem(typeof(MyCustomElement), ElementName="el2")]
public List<MyCustomElement> elements {get;set;}
@Neil sorry, I meant deserializing
 
oh well yeah that stinks
Either you have all the information you require to deserialize it properly or you don't
and even then, there may be no "nice" way of going about it
 
god dammed - I wish this would be json instead of soap :(
 
even with json, you can get shit like this
 
fair enough
 
11:07 AM
you wish it was protobuf instead of text-based data
 
well, then I'm going to create my own parser, fortunately it's not too many data in those tags
 
If I sent you an xmls containing a number of whitespaces equal to a number I wanted to send you, there'd be no way to get that number without adding custom code
 
thanks guys
 
just because generally that kind of shit is ugly and should never be done :P
 
ReadOnlySpan<char> based parser
 
11:09 AM
git out -now
 
git gud
 
@Wietlol Don't be such a div-a
 
any of yall live in Brighton?
 
You should be more flextable
 
V.7
@mr5 What app is this?
 
11:13 AM
Xcode?
 
V.7
Xcode is unnamed code. Meaning, it was coded by no name.
An author is unknown.
 
Xcode is garbage
 
@Wietlol what was missing?
 
19 hours ago, by Wietlol
the code parser tool basically has all antlr features +
- left recursive (and right recursive) patterns,
- inheritance based lexer tokens,
- type based pattern matching,
- priority based pattern lists (with some options of handling recursion)
- and dynamic grammar (the ability to add rules/options to the grammar at runtime)
(antlr has some form of left recursive patterns, but they are really not that great)
 
ok
 
11:18 AM
It's not that obvious the kinds of problems you run into making a code parser until you actually try to write one
especially if it is generic
 
isnt that true for every tool?
you dont understand the problems that the people writing your IDE have dealt with
you dont understand the problems that the people writing your compiler have dealt with
you dont understand the problems that the people writing your language have dealt with
you dont want to know the problems AWS and Azure devs have dealt with
 
you don't understand the problems that the people writing your language have dealt with
FTFY
 
@Wietlol No. I want to make a tool that prints out "Hello, World". Done. Already written.
Don't try to be philosophical, this doesn't apply to everything
 
Is there storm in England
 
There's 2 in quick succession
 
11:23 AM
I mean serious storm
 
We had Ciara like yesterday
Then we've got Dennis over the next few days
Relatively bad by our standards, but pretty tame by other places' standards
 
and they will have Wietlol the next week :D
 
It's fairly rare for us to get a properly bad storm
 
@Neil I mean every more complicated tool
if you want a CRM, go for it, but if you want something more complicated, expect issues you havent met yet
 
@Wietlol I want to make a tool that prints out "Hello, ${name}". Done. Already written.
you're just being pedantic
 
11:26 AM
obviously 2020 is a disaster year
 
many problems are difficult in a generic "not making any point whatsoever" kinda way, sure
 
!~shiba
 
wow :o
 
woof
 
11:28 AM
woof woof
 
doge ac/dc woof
 
:o
 
Things in C++ are starting to make sense. I'm worried.
 
11:32 AM
 
@AvnerShahar-Kashtan sense is the path of the dark side
 
C# == C++++
 
sense leads to C++
C++ leads to frustration
frustration leads to anger
anger leads to hate
hate leads to suffering
 
suffering leads to death
 
everything leads to death
especially corona
 
11:36 AM
if you drink too much
 
dead leads to rest
 
rest leads to unrest
unrest leads to undead
 
rest leads to graphql
 
@Hans1984 hahaha
 
11:43 AM
hehe
lazy squirrels
 
drunk squirrels
 
lol
 
they get free advertisement boost because of their name x)
 
yeah im sure they really wanna be associated with a thing killing a bunch of people
 
11:46 AM
I would like to see a sales graph of corona beer by country
 
@nyconing lol
 
over the past 3 years
 
Reminds me of the fact that there was once a product called "Ayds"
Not surprised they didn't survive the 80s
 
"by country"
hows their sales in china
giggles
 
for example
but also outside of china would be fun to see
why cant I download 4.5?
I want the developer pack
 
11:59 AM
dotnetfx45_full_x86_x64.exe
I got that in my repository
 
ye... I am not sure I want to run that dolphin
 
12:23 PM
"How did Joe Biden fall so far from grace?? ;~;"
 
what'd he do?
aside from being a creepy old man around young girls
 
he just lost hard last night
and the media can't figure out why cause they think he was the frontrunner at one poitn
 
I just see him as Obama's vp
 
even when he was VP, people thought he was an idiot
 
typical to be vice president and then attempt to run for president yourself afterwards
He was never a strong candidate in my eyes
I was surprised when Kamala dropped out of the race
I thought she had a chance
 
12:31 PM
now its the 4th day in a row where its very windy
reeally strange weather
and its pissing me off!
 
yep, very weird
 
Have you seen the Strandperle, Hans? Bistro on the Elbstrand in Hamburg, and you could only see the roof sticking out of the water!
Also strong wind is fun, as long as no tree hits me.
 
no, i Havent
yeah I can imagine its a lot worse by the sea
with this wind
 
tomorrow where I'm at, the temperature is gonna plummet
 
Plummet how much?
 
12:43 PM
there's a high of 33F and low of -3F
right now it's 27F and that's as low as it's gonna get
 
press F to pay respect
 
Uhh that's like 50 meters, right?
 
press C to receive sanity
!~convert 33F celsius
 
@Wietlol 18.3333 degC
 
!~convert -3F celsius
 
12:45 PM
@Wietlol -1.6667 degC
 
thank you ny for rounding to a max of 4 digits :D
!~> 5 / 3
 
!=>1
 
-_-
!~> 5.0 / 3.0
 
!=>1.6666666666666667
 
lol bot is getting clever
That is indeed a harsh plummetting of temperature
Jack, >5/3
 
12:52 PM
....Come Again?
 
Yes.
 
Jack, commands
Right...
 
Shame it runs on Javascript
 
Jack, kys
 
12:52 PM
:(
 
At least Jack runs on c#
 
Whats kys
 
kill yourself
 
kiss your self
 
12:53 PM
make love, not war
make jar, not war
 
Error: Ambiguous reference.
 
make exe, not jar
 
love :
	@echo "Don't war!"
^ it's inside every Makefile i have
 
make exe, not dll
 
@AvnerShahar-Kashtan what IDE for C++ at Google?
Vim?
(hope dies last)
 
12:56 PM
Probably some internal one because google
 
internal, mostly
 
Jetbrains
aw
at google, what languages do they use?
 
Go
 
last I heard was C++, Java, Javascript and Python
for the majority at least
 
Main languages are C++, Java, Python and Go.
 
12:58 PM
hmm... JS is out?
 
For web stuff, I assume it's used. *shrug*.
 
they literally made a language that converts from java to js
 
obviously Go in on there
 
why would they use js?
 
true...
 

« first day (3406 days earlier)      last day (1525 days later) »