« first day (1083 days earlier)      last day (2940 days later) » 

12:00 AM
RELOAD! There are 2160 unanswered questions (93.5453% answered)
 
@200_success It looks to me like the code in the fiddles is supporting code for demonstration
The code for review is not in the fiddles though, they must be outside elements that are used by the code up for review perhaps?
 
0
Q: How to call a Setter which returns the value because of immutable?

Christian GollhardtI have a Extension method, which sets a bit for an byte: public static byte SetBit(this byte b, int bitNumber, bool value) { if (value) { return (byte)(b | (1 << bitNumber)); } return (byte)(b & ~(1 << bitNumber)); } The problem is, because a byte is immutable, I need t...

 
12:19 AM
0
Q: Stack over Flow error

Mohammed AlsharfI'm trying here to develop an app that can get an array of char and then create another array of type char that have the same length of the original one, and then compare the random password to the original one. However, for some reason when the simulation run so many times I get a stackoverflow ...

 
@Phrancis don't comment on ^, it is clearly off-topic.
 
OK I deleted it
 
@Quill .... just why
 
@EasterlyIrk huh?
 
how does js get that from the code?
in the picture
 
12:33 AM
StackOverflowError is not when you run out of memory by natural process, but rather when you recurse too many times or something like that, clearly a code error?
 
I think so.
 
@EasterlyIrk are you asking how that works?
 
yes.
 
12:47 AM
@CaptainObvious nope. Code Review error.
 
12:58 AM
TIL about Java's join ... now I have 2 join problems
 
1:21 AM
@Phrancis class JoinProblemFactory extends ProblemFactory
 
lol
 
1:44 AM
@EBrown You should have proposed to her. </sarcasm> Hope she gets things straightened out and wasn't just selling herself to you.
 
IntelliJ is killing me with this bright green highlight, have no idea what it's supposed to mean
Not giving me any hints either
May be a bug on their end or something
 
0
Q: Extendable JavaScript module that converts between camelCase, PascalCase, and underscore_case

Josh DawsonThe basic idea is that by defining the basic functions--recognize, dissect, and combine--conversion between any case type is possible. recognize is meant to recognize a string of a given case type dissect is meant to break down a string into an array of lower case substrings according to the gi...

 
2:23 AM
0
Q: PHP Code for Adding Item to DB + JSON

Null SparkIs this code good? Or is it the noobiest PHP you've ever seen? <?php //Initialization Section require "helper.php"; $dest = "../forms/addhandout.php"; //Check for $_POST Data if(!$_POST) { send(array("msg" => "ERROR: No Data Recieved")); } else if(!isset($_POST["name"]) || $_POST["name"] =...

 
2:40 AM
@Phrancis when debugging? If that's the case and if it's anything like in VS then it's basically showing you where the thread came from - some sort of "in-code call stack"
 
@Mat'sMug It's not "debugging"specifically, but IntelliJ has a lot of "smart" things that analyze your code automagically... kinda like Rubberduck I wager
It would make sense, I guess, if it highlighted where a thread originates, just because threads
... aaaand, the highlight is gone ;-;
Cut out that line of code, put it back, and yeah, gone
Go figure
58 mins ago, by Phrancis
May be a bug on their end or something
 
I'm happy that you find my answer helpful and motivating. Good questions with nice MWE's always make me put in some extra effort. But this answer is a bit of an overkill for SO. It's maybe a more appropriate answer for CodeReview. The most straightforward and correct answer here would be the one from haifzhan. It answers directly to the asked question. Plus I kind of feel bad for stealing points. — ljetibo 45 secs ago
 
2:56 AM
0
Q: Suffix array algorithm

Lin MaI'm wondering if I can safely change this line: for (step = cnt = 1; (cnt >> 1) < n; step++, cnt <<= 1) to this: for (step = cnt = 1; cnt < n; step++, cnt <<= 1) import java.util.Arrays; import java.util.Scanner; public class StringSimilarity { static class SuffixArray { pub...

 
@ljetibo this would indeed make a great Code Review answer... maybe you should try answering some questions there! — Phrancis 1 min ago
 
3:22 AM
I kinda feel bad for me in 6 months.
I actually found myself copy-pasting code, do you think it's time I get it reviewed?
mea culpa
 
It's always time for a code review. well, assuming it works ;-)
 
It works
 
It's always time for a code review.
 
Posted
 
Java, the script, or something else (tm)?
 
3:38 AM
0
Q: Thread class for exercises

PhrancisI just felt a sting as for the first time, I copy-pasted code blocks, and made very little change to it, to overload it. It works fine, but I have 3 constructors that are basically copy-pasted. I'm hoping there is a smarter way to do this. In short, this creates a thread and runs it with 1, 2 or...

 
Tag synonyms: ->
@Phrancis surely Java can chain constructors
 
Um, it probably can, I guess I'll hear about it lol
You don't know what you don't know
 
3:57 AM
lol L_O_L
++ great answer but... Did you mean DEFAULT_SLEEP_TIME? ;-) — Phrancis 44 secs ago
 
namingConventionsSuck AM_I_RIGHT?
 
@Mat'sMug quick correction
private static final defaultSleepTime = 400;
private static final defaultNumLoops = 10;
needs int
 
oh wow, duh - fixed! thanks!
 
5
Q: User Watch List For Mods

mxyzplkAs a moderator, we often have a set of users on our SE we need to be watching carefully, because they're clearly in the throes of misbehaving but either haven't crossed the line yet to get suspended or are just back from a suspension and may not have used the time to self-correct their behavior. ...

Lemme just reboot that BigBrother project...
 
@Phrancis I find it interesting that you described your single-parameter ctor as your "default" one, and the other ones as "extras" - things get easier to envision when you consider the ctor that initialize all fields as your "main" and the ones with hard-wired defaults as "convenience" ctors.
 
4:09 AM
@Mat'sMug I think I was thinking in FP/Lisp
 
you're thinking in Lisp?!
(kidding)
 
Lisp is the epitomy of FP ;p
But anyways, I got your suggestions to work with minimal fixes
So, have an accept
 
> That said I'm not sure about start()ing the thread in the constructor; it makes your run method a bit misleading.
wait there's no const in Java?
 
Yes there is, it's final
 
wait there's no readonly in Java?
 
4:14 AM
Read above
const == readonly == YOU CAN'T CHANGE IT
 
const != readonly in my mind... I was thinking in C#
 
Looks much better though
 
0
Q: Live Wallpaper stops on preview

Mase WinduFollowing this tutorial here, I've trying to take a gif create a live wallpaper out of it. No prior background in java I've made it this far: import android.graphics.Movie; import android.graphics.PorterDuff; import android.service.wallpaper.WallpaperService; import android.graphics.Canvas; impo...

 
@Phrancis it does :)
I like having the least-parameterized ctor at the top though - the chain reads neatly top-to-bottom then
 
Uhh let me see how much fuss IntelliJ will give me if I do that
Oh,no complaints
 
4:18 AM
I got scared for a minute... Java doesn't care about the order of members, like [I think] C does, right?
(or Python)
 
Ehh
 
if it compiles, it doesn't care ;-)
 
It complained a bit before I switched it, but it could probably resolve it
IntelliJ complains a lot though, but usually for good reasons
 
@Phrancis it's JetBrains... they're pretty good at complaining about one's code
 
@Mat'sMug It's usually justified :)
 
4:21 AM
absolutely
irony:
in VBA Rubberducking, 38 mins ago, by Comintern
R# needs a rubber duck sometimes.
 
It's just now telling me the public aren't needed
 
@Phrancis because you're only calling them from within the class itself
 
Bingo
But also on the class, because I'm only using it in this package.
 
lol
 
This IDE really gets sad if you write bad code like I do
3
 
4:24 AM
 
There is one thing that bugs me, if you have overloaded methods or ctors, and only some of them need to be, say, public, it will suggest you remove that public from the other ones
 
if only some of them need to be public, then you don't need the overloads
 
It would of course fire a warning to the caller of those others, but it just bugs me that the same thing would have different access levels depending on what arguments they are called with
Hm, fair point
Oh, I also meant an exception, not a warning ._.
such words, wow, very meaning
@Mat'sMug thx
 
4:41 AM
aww
 
brb installing Flash ;-;
 
@Phrancis FINE_YOU_WIN ;-)
 
5:35 AM
Stack Overflow is mainly for problems to be solved. If your code is doing what you expect it to do and you want an expert opinion how to improve it, head over to the guys at Code Review. — nvoigt 58 secs ago
 
5:47 AM
0
Q: Tic Tac Toe C++ follow up

chris360I have finally found some time to redo the last tic tac toe game I posted. I have gotten rid of "Magic Numbers" as well as any typos(if their are any please point them out but I think i rid myself of them...hopefully). I have updated the way the code is implemented as well as added a header title...

 
in VBA Rubberducking, 25 secs ago, by Mat's Mug
note to self: run the damn thing before pushing
in VBA Rubberducking, 42 secs ago, by Duga
[retailcoder/Rubberduck] retailcoder pushed commit b341c346 to next: fixed off-by-one (gotta love these lovely 1-based COM collections)
 
6:06 AM
0
Q: linked list in c code

Code FoxI have implemented linked list data structure in c.Please review my code. Thanks in advance :) linkedlist.h #ifndef LINKED_LIST #define LINKED_LIST #include <stdbool.h> struct linkedlist { int key; struct linkedlist* next; struct linkedlist* prev; }; bool list_insert(struct linke...

 
6:29 AM
@Mat'sMug All collection types should start with 0 or 1 :)
 
@Phrancis in .net everything is 0-based. COM interop is very much subject to off-by-ones!
 
0
Q: Topological sort using recursive DFS

CodingBatmanI am currently learning Graph algorithms by solving questions on online judges. Also, it is my first time with C++ STL. Kindly review my working code below and provide me with feedback. The exact question for the below code is here: http://www.spoj.com/problems/PFDEP/ #include<cstdio> #include<...

 
@Mat'sMug sounds groanful
C headers also sound pretty terrible
@CaptainObvious I tried to retitle it, but stumbled upon many titles already used
eh ttgtb
 
me too
'night!
 
6:48 AM
Did you leave @Mat'sMug
had a quick question
actually @Phrancis might be able to answer my question as well
Damn it. everybody left.
I need somebody who has ever contributed on a third party github repo
 
7:03 AM
@Hosch250 Nah, I don't think it'll work out. She has too many problems with her kid and wants to move to Florida, whereas I am being fast-tracked to management or Information Systems for the company I work for, which means I'd have to either move to Iowa or Wisconsin.
Yesterday, we got 19 more accepted answers, 34 more questions were answered, 48 more answers were posted, 146 badges were earned, 173 comments were left, 38 more questions were asked, 4 more questions were unanswered, 94 users were created, and 340 votes were created.
Our question answer accept rate went down by 0.0104%.
Our question answer rate went down by 0.0046%, and our answer accept rate went up by 0.0039%.
 
7:20 AM
remonkevening
 
Can I actually copy mine own answer from another not SE site to here?
 
depends I guess
 
As I'm the author I don't need to make the reference correct?
 
you could make it to be sure, but if you're the author then it's probably okay
 
0
A: ZK grid scroll bar problems

chillworldIf you don't use the native scrollbar your issue is fixed and your data is still all readable : <grid height="150px" hflex="min"> <custom-attributes org.zkoss.zul.nativebar="false"/> <columns> <column label="one"/> <column label="two"/> </columns> <rows> <row> ...

 
7:22 AM
Read the "zkoss.org" ToS.
 
I know at ZK they don't shoot me, I'm working freelance for them ;)
 
looks like a stack overflow reskin ;-;
why do so many help forums just emulate SO now ;-;
 
well the badges don't work correct there ;)
 
@Quill Methinks that user is the same as the SO one.
Usernames are "AndriySV" and "Andrii", the user on SO has exactly one question (same question) and it was posted yesterday.
 
The description is word for word the same
besides some spelling edits
 
7:26 AM
Yeah cross post, but for SE it doesn't matter because cross post is not on SE site
 
yeah
that's really weird though
 
but that's why I also answered it here, if users find it here
thx santa ;-)
 
Monking
 
It's definitely monking.
 
@Phrancis are animated gifs not allowed or are oneboxed animated gifs not allowed? difference being important
 
7:44 AM
0
Q: Pong game implemented in java using JavaFX

Jedi18I'v almost finished my first pong game in java. I tried using swing but later on decided to try JavaFX instead. Both the paddles are controlled by the user, one by WASD and the other by the arrow keys. I have a few issues with this though :- 1) If I hit the ball while going up(I mean if the ba...

 
Hmm... git-tfs is rewriting my commits :(
 
Zak
Monking @all
 
monking @Zak
 
Monking @zak
 
TIL you can set up git to always attempt to rebase when doing a pull
$ git log
6ab13dc in the future [redacted email] check that the previous primaries exist before adding them back to the array
interesting time, git
(in the future is the "relative" time)
 
7:51 AM
monking @DanPantry
 
it was @zak who just arrived
 
@DanPantry yea I like the idea, but generally sheet solutions are a problem more than a solution
Monking
 
@Vogel612 I would just rather pull not automatically do a merge commit
 
I just got one of these in a loot crate
 
So I have the choice of either setting it to do a rebase or doing git fetch / git rebase
and I am lazy :D
 
7:54 AM
@DanPantry that's not always possible
sec
 
@Vogel612 well, of course
if it can't do a ff it will fail
but I'd rather it fail loudly than silently create a merge commit which I then have to clean up
besides, the branches I am pulling from - develop and master - are both guaranteed to have ff histories
 
why not pull --ff-only then?
 
that option exists? TIL
git has so much stuff
can that be configured in ~/.gitconfig?
 
@DanPantry Linus has the magic abilities of making cool stuff
 
no clue
but you can pass it directly to pull when doing that
 
7:56 AM
Yeah I know @Vogel612, just not as easy to remember. I guess I could alias it to git p or something
Learning git is a bit like mountain climbing; but instead of starting with small cliffs and progressing to tougher ones, git makes you climb the same mountain again and again, only to fall at different heights each time, every time just as surprised that the lifeline wasn't attached. — conny Mar 23 '10 at 15:52
2
 
Ripe zombie; open question with answers, at least one answer having score 0, no answer having score > 0: Finding the minimum from a sorted rotated array with duplicates
 
windows file locking is annoying
 
Just use programs which don't lock, like Notepad++.
 
It's difficult to use notepad++ when you need to run a c# program :p
monking btw
 
@DanPantry soo... roslyn integrated into emacs not an option?
 
8:04 AM
@Vogel612 emacs is not an option on account of the fact I don't want to go insane
omg git is awesome
 
IIUC atom can do plugins ...
 
@Vogel612 I don't use atom
 
sublime? Anything reasonable for webdev?
 
I use sublime
 
they have plugins right ?
 
8:05 AM
WebStorm is okay, but atom gets to have the cake and eat it too
 
I think all of those can be tricked into compiling C#.
 
@Vogel612 Yeah, but I haven't found a Roslyn one yet
They can all compile C#
Running C# projects through IIS express is another matter
 
@Mast s/tricked/forced at gunpoint/
 
Never mind the fact that I'd have to manually update the project files each time I added/removed a file
"Oh, Dan, can you put X fix from the master branch on Y very old version for the UAT release?"
 
lol
 
8:06 AM
On TFS? nope. On git? git checkout <tag>; git reflog <filepath>; git cherry-pick <commit>
 
@DanPantry git cherry-pick
 
this is why git is awesome. and why git done properly is even better
3
 
@DanPantry don't forget to tag correctly again
if you checkout away you'll loose the work you done again
 
retag under same version or no? I would xpect to retag under something like 1.0.8.4-.... or something
(version numbers are sentimental)
 
depends a little
are you releasing that version?
are you following semantic versioning strictly
 
8:11 AM
> (version numbers are sentimental)
it is a fix to version 1.0.8.4
 
either increment the last or don't I'd say
unrelated: my dog is officially a cat...
3
Working with my laptop. Dog comes looks at me. Gets onto my lap and then lays his head and upper body onto the whole keyboard...
anyways... BBIAB University and stuffz
 
0
Q: Add item after every nth step

DumpenThe purpose of the method is to add a list of items after every nth step (5 for example) where the input items are repeated if needed. I'm looking for an overall review and possible how to remove the use of the while and replace it with a for. public static List<string> AddEveryNthStep(List<string>

 
8:33 AM
@Vogel612 Awwwwww.
ffs, I think I'm being bitten by line endings again
 
8:46 AM
I just added a _override-bootstrap module to my solution
If only I could append !important to all of the rules automatically...
 
quick attempt in this chat, if it fails I'll try SO:
given an interface MyInterface, and a class A and B both implementing such an interface, how do I rig my method so that it allows List<A> and List<B>, but not List<MyInterface>?
 
give it a type-bound Generics declaration
 
@Quill and bootstrap-sass?
 
and that if in the future, C implements MyInterface is made, it'll take List<C> without alterations?
 
public <T extends MyInterface> void  method(List<T> param)
 
8:56 AM
@DanPantry I am using SASS
 
@Pimgd yeap.
 
@Vogel612 this accepts List<MyInterface>
 
no, I'm not using bootstrap sass
 
@Pimgd and that's not acceptable?
because if it isn't your're basically fudged
 
It is not acceptable because I want it to be hard to give me a list containing various A and B
 
8:58 AM
congrats you're fudged
 
wooo
 
@Pimgd unless A and B extend a common type you're buggered
 
The easy solution is to swap to javascript
 
that's impossible to check at compile time in java, because type-bounds are not unifying, but intersecting
 
the hard solution is to swap to python
 
8:59 AM
@Vogel612 If they both extend the same interface, wouldnt' that work? (I know that is what is already being discussed)
 
while it's possible to use <T extends A, B> it doesn't do what you want
@DanPantry that allows a mixed list
 
No, when I said extend a common type I meant List<T extends Interface> or List<Interface>
 
can I use "not"
 
because then you can pass a List<Interface>, where both instances of A and instances of B can be inside
 
And that's not acceptable? (I haven't read half of the issue)
 
9:00 AM
<T extends I && !(T super I)> sort of thing
 
If that's not acecptable, welp. gl
@Pimgd uh.. no
 
@Pimgd lol it's java
as if generics had a useful feature
 
That doesn't work in C#, either
And switching to JavaScript isn't the answer - JavaScript won't throw up at compile time but it will throw up at runtime unless the types are union types.
 
I'm not looking for that specific syntax =D but some way to exclude types would have helped too
 
@Pimgd AFAIK generics are "inclusion-only" rather than "exclusion-only".
 
9:01 AM
^that
 
Oh, I treat all the items in the list as MyInterface
 
And, to be honest, that makes a lot more sense. KISS. Imagine the mental gymnastics if you could say "I'm letting A and B but not C even though C extends A"
 
adding a layer of context, I gotta merge objects
 
@Pimgd okay then you don't need to check and should just use the interface as type-bound
 
it would completely violate the Liskov Substitution Principle
 
9:02 AM
I'm not violating that
 
No, but the not parameter you asked for would ^^
 
@Pimgd why not throw IAE with a mixed collection?
 
doable but less awesome =/
 
you're using Java, by default it's less awesome.
;-)
 
stab stab stab stab
public interface Mergeable<T extends Mergeable<? super T>> extends Comparable<T>
{
    Class<T> getGenericClass();
    List<T> merge(T with);
}
 
9:04 AM
ouch
shame there's no "any" type in Java
 
I'm not sure the Comparable's generic type bound is correct yet
 
what do you mean
 
looks like you're trying to make a union/intersection type, right?
 
@DanPantry there is supposed to be in java 9 IIUC
because primitive-generics crutch
 
I want to make it possible to pass a list of mergable objects to a merger which merges them (wow pim that's helpful)
it's for importing data from tables which don't know what normalization is
 
9:06 AM
@Pimgd in JS there's an any type that is, well, anything
 
merge two employees with the same employee id and different employment dates on different locations to be one employee that worked in two places for a period
that sort of thing
oh boy
 
Interesting side effect of setting your VPN location to auto: you get to learn about all the insurance companies and cellphone carriers of all kinds of countries
 
another part of the whole plan blew up and now I'm more screwed
 
0
Q: Optimizing quicksort partition method/function for duplicate elements

mazidI'm a newbie and interested in learning different data structures and algorithms. While implementing quicksort, I found this code works pretty well for partitioning. int partition(int ar[], int lft, int rgt) { int left = lft; int right = rgt; /*median of three is the best pivot value to accompl...

 
some of them objects already implement Comparable
 
9:10 AM
lol, good luck
 
haha
yeah =/
hmmmmhhhhhh well Mergeable could just NOT require Comparable
but the method would
 
why not make the generic type bound of mergeable extend Comparable
and wrap the Object you want to merge into Mergeable?
 
clever
 
$ git push origin --follow-tags $(git tag -l)
Why did I have to specify the tags explicitly..? --all wasn't working with --follow-tags
 
public interface Mergeable<T extends Mergeable<? super T> & Comparable<? super T>>
Like that
 
9:15 AM
Comparable<? super T>>
that's a weird kind of PHP
 
@DanPantry just use git push -t
 
@Vogel612 ty
 
since you push all tags anyways :D
 
@Vogel is git master
 
generics are fun, in a dwarf fortress way
 
9:18 AM
@Quill meh... not really
maybe advanced, but definitely not master
 
@Vogel612 I appreciate the help, anyway. I've only really been really looking into git in the past few months
 
though it helps to understand how it works internally
 
Like, I've used git for years, but I've only just recently started looking beyond branches and commits
 
9:23 AM
Every time I try something new with it, I refer to the chart.
 
Which chart?
 
Since there's no way I can remember all of it.
@DanPantry Cheat-sheets.
 
Those are pretty basic, though. It would be good if it showed you how to (easily) compare changes with a remote branch that has been git fetched
without it just being diff...
I believe an easy ish way is git log develop...origin/develop
 
That, and a boatload of PDFs I store.
And still, with all that knowledge at the tips of my fingers, git is hard.
So easy to screw things up and notice way too late.
 
0
Q: K-means clustering in Rust

lochshI've implemented K-means clustering in Rust. It's my second Rust project (my first one is here: Randomly selecting an adjective and noun, combining them into a message) I would like advice on whether I am doing stuff idiomatically, and any sensible optimisations I could make. I also appreciate...

 
9:30 AM
@CaptainObvious Good question, throw some upvotes.
 
0
Q: Beginner Java: a variable in an object created prevously

Nathan SSSSSSHi guys I am taking a java course at uni and ive run into a problem halfway through an assignment. Im currently out of the country so its very difficult to get my tutor to help. The assignment is to create a two player dice throwing game with text menu's through console. I have 3 classes, Game, P...

0
Q: Outputting multiple looking-alike elements in React

Rishat MuhametshinI believe this is a classic problem when you have a component that outputs a bunch of similar DOM elements. Be it a list of answers to a question, or table rows, or whatever. So, I have tried many ways, and what I've come up with is, conceptually, only render function queries component props an...

 
@CaptainObvious looks like example
XBOX 360 has been discontinued after it was released 10 years ago.
OKAY.
 
9:47 AM
subclassing comparables, bleh
	@Override
	public int compareTo(Superclass instance)
	{
		if(instance instanceof ThisSubclass)
		{
			return compareTo((ThisSubclass) instance);
		}
		return super.compareTo(instance);
	}
you end up with crap like that
 
Read JavaScript's type system on http://418stat.us at http://418stat.us/2016/04/javascripts-type-system/
Yay new blog post!
 
 
my console is adding syntax highlighting
 
I get the whole "wtf",
but five++ and then later five is obviously 6
2
 
Turns out 0% battery on a Mac makes the mouse and keyboard really laggy
 
9:52 AM
that's how postincrement works
 
I wasn't focusing on postincrement
I was focusing on the whole "now I can't set five.wtf"
 
@Quill I don't get it - screen is off, how do you see the mouse not move and the text not type when the screen is off
 
wtf
 
My battery indicator literally said 0% for 5 minutes
 
NODE_ENV=production webpack
Java installer pops up
wot
 
9:53 AM
It means your computer wants more coffee
pour coffee over computer to solve problem. /s
 
@Pimgd this entire sample does actually make sense, and the only reason it goes fubar is because of function() { return this }.call(5)
five++ returns 5 because you return the 5 object and then increment it
if you did ++five it would work as you expected
 
I was focusing on how five starts out as a wrapper type
 
yea that's because of the call
 
++five and five++ still change it from a wrapper type to a value type
 
return this will return a boxed version of 5
 
9:56 AM
@Pimgd That's about the only thing making sense in that picture though.
 
I couldn't find a definition for why that happens...
 
Welcome to the odd world of JavaScript.
 
@Quill it doesn't return a value type
it still returns a boxed type
you can't assign properties to primitives
 
Yes, I couldn't find a reason that .call returns a boxed type
 
probably because this becomes boxed (not sure why)
it becomes boxed probably because it needs to be treated as an object otherwise things fall apart
if you passed in a value type as this and then modified this, it wouldn't work as you'd expect
because when the function ended, this would not be modified
boxing it makes sure it adheres to POLA
who am I kidding, let's just hate on javascript
 
9:58 AM
why would it need to be an wrapper type
 
Because if you try and modify a value type
The changes will be lost once the function ends
because it is a value type
by boxing it to a wrapper type it becomes a reference, and so you can assign properties etc to it
 

« first day (1083 days earlier)      last day (2940 days later) »