« first day (1135 days earlier)      last day (2045 days later) » 

00:00
RELOAD!
[rubberduck-vba/Rubberduck] 3 commits. 3 opened issues. 2 closed issues. 19 issue comments. 3740 additions. 321 deletions.
 
1 hour later…
01:03
> Rubberduck.Setup.2.0.13.0.exe (5.83 MiB) - Downloaded 2525 times.
Last updated on 2017-03-12
> Total Downloads 12,884
 
9 hours later…
10:14
@IvenBach I think you might profit a lot from reading C# in depth. It explains generics in quite some detail in part 2 (the one about C#2) and part 3 (the one about C#3) is basically about 150 pages explaining LINQ and its building blocks.
6
 
2 hours later…
11:50
I have a PublicNotCreatable class in an addin (along with a public constructor):
Option Explicit

Private pwd As String

Public Sub SetPassword(ByVal password As String)
  pwd = password
End Sub
^ i.e. it's a write-only, encapsulated password. The field is private.
but thanks to CopyMemory...
in another project that references the addin:
Private Declare Sub CopyMemory Lib "kernel32.dll" Alias "RtlMoveMemory" (ByRef Destination As Any, ByRef Source As Any, ByVal Length As Long)

Sub test1()

  Const SECRET_PASSWORD As String = "Secret Squirrel"

  Dim c As Class1
  Set c = GetClass1

  c.SetPassword SECRET_PASSWORD

  Dim instancePointer As Long
  instancePointer = ObjPtr(c) + &H34

  Dim fieldPointer As Long
  CopyMemory fieldPointer, ByVal instancePointer, 4&

  Dim stringLengthPointer As Long
  stringLengthPointer = fieldPointer - 4
sure, that &h34 is a magic number that works for this COM object, but encapsulation is DOA.
12:23
This is just showing that encapsulation is not a sufficient security measure.
 
2 hours later…
14:41
reads the reference counter on a class instance
contemplates changing it - contemplates the memory leaks
@M.Doerner aye, but if I can read the function pointers (including IUnknown/IDispatch pointers), and the fields (including the reference count field), and the interface IIDs, then I think I have a pretty good start on analyzing a class instance's memory layout.
If I can that working for an ObjPtr, then I think I can get it working for a VBE-level pointer I found that I think exposes IPersist and ITypeLib
@Mat'sMug ^ hands in the guts - might be able to get a handle to VBA's APC.
15:00
0
Q: Create a auto installer as add-ins and assign buttons on ribbon in VBA

QuickSilverI will need a code review for the below auto installer as addins that will also create a tab on the ribbon with buttons and have assign macros automatically. If possible any advice on if this is a good method of doing it or there is something better, i'm looking for this to be compatible with exc...

15:21
// for IVbaProjItem::GetItemType
typedef enum {
	VBAPIT_StdModule,
	VBAPIT_ClassModule,
	VBAPIT_Designer,
	VBAPIT_DocumentObject,
	VBAPIT_DocumentClass,
	VBAPIT_Other
} VBAPROJITEMTYPE;
I want to know which host implements a DocumentObject
16:14
I don't know if anyone here will find this interesting or not, but I think it confirms where we already know there are issues. gist.github.com/rubberduck203/a7c02d87b1725a07e97cc36543953c27
Top 100 changed files ^
These ones I thought were particularly interesting.

```
761 Rubberduck.Parsing/VBA/RubberduckParserState.cs
716 Rubberduck.Parsing/VBA/RubberduckParser.cs
...
651 Rubberduck.Parsing/Rubberduck.Parsing.csproj
...
442 Rubberduck.Parsing/Symbols/IdentifierReferenceResolver.cs
...
281 RetailCoder.VBE/UI/SourceControl/SourceControlViewViewModel.cs
```
16:50
> We are reresolving all modules that reference modules or references that got removed. This is necessary because the same identifers might now resolve to different declarations. So far, a cancellation of a parsing run in which modules got removed caused us to loose the information that the modules referencing the removed modules had to be reresolved. Moreover, a parser error in some other module changed in the meantime would have caused the same loss. With the changes in this PR this...
[rubberduck-vba/Rubberduck] build for commit faa3af02 on unknown branch: AppVeyor build succeeded
 
2 hours later…
19:03
@RubberDuck You need to let your tool exclude file types and folders.
You should filter the .csproj's out.
And maybe the test folder.
19:22
@Duga @M.Doerner mind if I take this and turn it into "Inside Rubberduck pt.2"?
Thanks a million for taking the time to write this!
4
@Mat'sMug Just wait a bit longer. I still have two sections to write.
I will probably do that tomorrow.
sure.. do you want to write/publish the actual WP / RD News post? I'll add you as an author on the blog if you want
(I'm still reading - it's excellent btw)
I'll add a preamble about Declaration and IdentifierReference
@Duga @M.Doerner Thanks for writing this! It's very informative. Do you mind if I edit it for punctuation and spelling?
19:49
@Hosch250 a filter would be a nice convenience compared to gitnstats | grep -oP .+\.cs$ I'll add it to the backlog.
I wouldn't want to make assumptions for the user, so I wouldn't filter anything, but letting the user specify some filters would be nice.
 
2 hours later…
21:35
@shadowofsilicon Feel free to apply any corrections you find necessary.
22:26
@RubberDuck Of course.
22:43
@M.Doerner I hope to, that's why I went ahead and bought it.
To be honest, I am reading it myself at the moment. I am somewhere in the middle of part 3.
I don't think it's possible to regret the $ spent on that book. It's essential for every C# dev IMO.
I still reference it from time to time.
23:08
@IvenBach I have learnt a new law, exp-platform.com/Documents/TwymansLaw.pdf. Interestingly that he is a statistician who noticed errors from practical people are useful as use cases like on slide number 5.

« first day (1135 days earlier)      last day (2045 days later) »