Recent

Author Topic: bad message generated searching for units with the same starting name (FPC)  (Read 1239 times)

marcov

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8731
  • FPC developer.
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #15 on: September 16, 2020, 11:13:15 am »
The filesearching cache is afaik in compiler/cfileutl.pas.  For dos and win32 there is short filename (8.3) generation there + tests. For Linux no such thing exists.

But it could also be that in the unitname to search there are multiple calls to the filecache, so that the difference is somewhere else.


FPK

  • Moderator
  • Jr. Member
  • *****
  • Posts: 83
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #16 on: September 16, 2020, 09:16:53 pm »
For history reasons, the compiler searches also the 8 char name if a ppu with the full name cannot be found. The full name of a unit is always stored in the ppu. So if graphics32.ppu is missing, the compiler searches graphics.ppu: when loading this ppu, the full name is known and it is graphics instead of the graphics32 that the compiler expects in the mentioned case. As I understand the error message maybe somebody can suggest an improvement :)

marcov

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8731
  • FPC developer.
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #17 on: September 16, 2020, 09:26:22 pm »
But since we don't support win9x anymore, how long should we hold on to this?

Since this (graphics32 vs graphics) is a Delphi compatibility violation as much as the other thing is a TP compat problem.

Bart

  • Hero Member
  • *****
  • Posts: 3912
    • Bart en Mariska's Webstek
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #18 on: September 16, 2020, 10:07:42 pm »
But since we don't support win9x anymore, how long should we hold on to this?

But we do support DOS...

Bart

marcov

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8731
  • FPC developer.
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #19 on: September 16, 2020, 10:09:49 pm »
But since we don't support win9x anymore, how long should we hold on to this?

But we do support DOS...

Sure. So keep it for DOS hosts. And require are parameter to enable it for the rest. But don't force this anachronism as a default for everybody.

p.s. how much dos development is actually still hosted on pure dos nowadays ?

Bart

  • Hero Member
  • *****
  • Posts: 3912
    • Bart en Mariska's Webstek
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #20 on: September 16, 2020, 10:30:48 pm »
I'm tempted to give it a try.
I have a "pure DOS" as a VM, just to run TP6 as a reference for possible bugs.
I failed to set up XMM memory (which some of my old programs used to swap out the program when executing another program) though.

Bart

jamie

  • Hero Member
  • *****
  • Posts: 3538
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #21 on: September 16, 2020, 10:53:05 pm »
I am glad someone is taking some interest here.
 :)
The only true wisdom is knowing you know nothing

denis.totoliciu

  • New Member
  • *
  • Posts: 21
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #22 on: September 17, 2020, 12:05:06 am »
As I understand the error message maybe somebody can suggest an improvement :)

I have talked to a friend that is specialized in UX Design & UX Writing and have presented to him the issue related to the error message. He sent me two articles covering the problems that UX Writing is covering that I will post below and have extracted a few paragraphs that seem to be related to the issue discussed in this topic.

https://www.nngroup.com/articles/ten-usability-heuristics/
Quote
#9: Help users recognize, diagnose, and recover from errors

Error messages should be expressed in plain language (no codes), precisely indicate the problem, and constructively suggest a solution.

https://careerfoundry.com/en/blog/ux-design/ux-writing-what-does-a-ux-writer-actually-do/
Quote
as these digital products become more a part of our daily lives, we as users seek out those that give us the most natural and fluid experience. These changes in the way we interact with technology have led to the creation of UX writing as a discipline in its own right.
Quote
Finally, in a more philosophical sense, UX writers must fight for their users. So whenever a designer, developer, or product manager suggests something that might be unclear to the user, the UX writer must stand up and say how that feature, task, or project can and should be communicated more clearly.

I am no UX designer, nor UX writer, but it is quite helpful for everbody to get a grasp of the idea that user interface and text messages have their purpose that computer programmers tend to overlook. This happens because of many reasons amongst which probably the first one that comes to mind is that a programmer is interested mainly in the technical aspects and there is a lot of work to do already in that spot.

Talking about the taxis of an error message seems at first ridiculous when compared to the technically challenging problems within a compiler. At the same time, these small unnoticeable problems piled up together have the ability to degrade software overall by being perceived as unkempt, something that Delphi hasn't managed to resolve not even today with all its annoying tiny slips.

So this has nothing to do with ego, but more with what it says in the following quote from the article pointed by the second link:
Quote
Working in UX requires that you put your ego aside and remain open to different ideas and suggestions. It’s not about you—it’s about the alignment of user needs and business goals. This means you must be able to put your ego aside, listen to feedback, and remain open to new ideas.

avra

  • Hero Member
  • *****
  • Posts: 2003
    • Additional info
Re: bad message generated searching for units with the same starting name (FPC)
« Reply #23 on: September 17, 2020, 02:56:57 pm »
But since we don't support win9x anymore, how long should we hold on to this?

But we do support DOS...

Sure. So keep it for DOS hosts. And require are parameter to enable it for the rest. But don't force this anachronism as a default for everybody.
+1

Besides, when truncating LFN to 8.3, shouldn't short name of MyLongFileName.ppu look like MYLONG~1.PPU or similar? That can be differentiated from MYLONGFI.PPU in code.
ct2laz - Conversion between Lazarus and CodeTyphon
bithelpers - Bit manipulation for standard types
pasettimino - Siemens S7 PLC lib

 

TinyPortal © 2005-2018