[fpc-pascal] BSON formatter

2020-05-07 Thread Ryan Joseph via fpc-pascal
Working on the language server it's become clear that JSON is going to be a killer bottleneck, but that's what Microsoft decided to use. It's almost a deal breaker just because of the sheer size of the data due to JSON's verbose plain text formatting. I've seen there is such thing as BSON

Re: [fpc-pascal] BSON formatter

2020-05-07 Thread Michael Van Canneyt
On Thu, 7 May 2020, Ryan Joseph via fpc-pascal wrote: Working on the language server it's become clear that JSON is going to be a killer bottleneck, but that's what Microsoft decided to use. It's almost a deal breaker just because of the sheer size of the data due to JSON's verbose plain

Re: [fpc-pascal] BSON formatter

2020-05-07 Thread Andreas Schneider
Am 2020-05-07 08:40, schrieb Ryan Joseph via fpc-pascal: Working on the language server it's become clear that JSON is going to be a killer bottleneck, but that's what Microsoft decided to use. It's almost a deal breaker just because of the sheer size of the data due to JSON's verbose plain text

Re: [fpc-pascal] Bugs in StrToHostAddr6 in sockets unit

2020-05-07 Thread Noel Duffy via fpc-pascal
On 7/05/20 9:17 pm, Michael Van Canneyt wrote: On Thu, 7 May 2020, Noel Duffy via fpc-pascal wrote: Great. My worry was that the sockets unit might fall into the same category as the libc one, available but deprecated and not recommended for use. Plus, when rewriting something that's been

Re: [fpc-pascal] Bugs in StrToHostAddr6 in sockets unit

2020-05-07 Thread Michael Van Canneyt
On Thu, 7 May 2020, Noel Duffy via fpc-pascal wrote: On 7/05/20 9:17 pm, Michael Van Canneyt wrote: On Thu, 7 May 2020, Noel Duffy via fpc-pascal wrote: Great. My worry was that the sockets unit might fall into the same category as the libc one, available but deprecated and not

Re: [fpc-pascal] Using include files in code tools

2020-05-07 Thread Mattias Gaertner via fpc-pascal
On Thu, 7 May 2020 16:26:12 +0700 Ryan Joseph via fpc-pascal wrote: > When using code tools I've found that it needs to start from a main > unit (otherwise other relevant macros may not be set) and then insert > includes into the source text. This is fine but when I inspect the > node tree

Re: [fpc-pascal] Using include files in code tools

2020-05-07 Thread Mattias Gaertner via fpc-pascal
On Thu, 7 May 2020 12:26:53 +0200 Mattias Gaertner via fpc-pascal wrote: >[...]how do I know which include a > > node came from? > > Nodes are always associated with a Tool. Tool.MainFilename gives the > file, where parsing started. > > > I need this information so I can get navigate to the

Re: [fpc-pascal] Bugs in StrToHostAddr6 in sockets unit

2020-05-07 Thread Michael Van Canneyt
On Thu, 7 May 2020, Noel Duffy via fpc-pascal wrote: On 6/05/20 11:21 pm, Christo Crause via fpc-pascal wrote: > On Wed, May 6, 2020 at 12:19 PM Noel Duffy via fpc-pascal > > > wrote: > > So I guess the question is, is it worth the effort to make >

Re: [fpc-pascal] BSON formatter

2020-05-07 Thread Michael Van Canneyt
On Thu, 7 May 2020, Andreas Schneider wrote: Am 2020-05-07 08:40, schrieb Ryan Joseph via fpc-pascal: Working on the language server it's become clear that JSON is going to be a killer bottleneck, but that's what Microsoft decided to use. It's almost a deal breaker just because of the sheer

Re: [fpc-pascal] Bugs in StrToHostAddr6 in sockets unit

2020-05-07 Thread Noel Duffy via fpc-pascal
On 6/05/20 11:21 pm, Christo Crause via fpc-pascal wrote: > On Wed, May 6, 2020 at 12:19 PM Noel Duffy via fpc-pascal > > > wrote: > > So I guess the question is, is it worth the effort to make > StrToHostAddr6 RFC4291 compliant? Is that something

Re: [fpc-pascal] Bugs in StrToHostAddr6 in sockets unit

2020-05-07 Thread Noel Duffy via fpc-pascal
On 6/05/20 11:40 pm, Karoly Balogh (Charlie/SGR) wrote: As much as we use the compiler and associated libraries ourselves, we can't cover every use case, or find every bug. A lot of packages are there for completeness, or because someone submitted it, or for compatibility with Delphi, not

[fpc-pascal] Using include files in code tools

2020-05-07 Thread Ryan Joseph via fpc-pascal
When using code tools I've found that it needs to start from a main unit (otherwise other relevant macros may not be set) and then insert includes into the source text. This is fine but when I inspect the node tree (TCodeTreeNode) how do I know which include a node came from? I need this

Re: [fpc-pascal] Using include files in code tools

2020-05-07 Thread Ryan Joseph via fpc-pascal
> On May 7, 2020, at 5:26 PM, Mattias Gaertner via fpc-pascal > wrote: > > Nodes are always associated with a Tool. Tool.MainFilename gives the > file, where parsing started. > Just curious, can you explain the reasoning of "tools"? I haven't exactly figured out the delegation of tasks in

Re: [fpc-pascal] BSON formatter

2020-05-07 Thread Ryan Joseph via fpc-pascal
> On May 7, 2020, at 4:44 PM, Michael Van Canneyt > wrote: > > I'm not even sure BSON will be accepted for LSP. I talked to them already and they're not keen to add extensions to the plugin so I'll probably give up on this route. The spec from Microsoft doesn't say anything about this

Re: [fpc-pascal] BSON formatter

2020-05-07 Thread Michael Van Canneyt
On Thu, 7 May 2020, Ryan Joseph via fpc-pascal wrote: On May 7, 2020, at 4:44 PM, Michael Van Canneyt wrote: I'm not even sure BSON will be accepted for LSP. I talked to them already and they're not keen to add extensions to the plugin so I'll probably give up on this route. The spec

Re: [fpc-pascal] BSON formatter

2020-05-07 Thread Andreas Schneider
Am 2020-05-07 15:26, schrieb Ryan Joseph via fpc-pascal: The amount of redundant information being sent around is ridiculous. Mainly, the spec gives no way for the client to cache results and refer to them later in various requests. We're literally sending around mega bytes of data for no reason

Re: [fpc-pascal] BSON formatter

2020-05-07 Thread Ryan Joseph via fpc-pascal
> On May 7, 2020, at 9:11 PM, Michael Van Canneyt > wrote: > > At least partial updates to a file should be there. > Sending the whole file at essentially every few keystrokes is just > braindead... > That's still happening but it's Sublime Texts fault for a bad API. It is fixed in the

Re: [fpc-pascal] Bugs in StrToHostAddr6 in sockets unit

2020-05-07 Thread Noel Duffy via fpc-pascal
On 7/05/20 9:43 pm, Michael Van Canneyt wrote: On Thu, 7 May 2020, Noel Duffy via fpc-pascal wrote: Well, considering the amount of RFCs I implemented for FPC, I think I'll join you. Let me know what golf course you picked. If your email address is any indication, new zealand is a bit far off,