Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 07/14/19 in all areas

  1. In Delphi Rio 10.3.1, the Project is configured for Debugging: Steps: 1. First I make sure that all source files are saved. 2. Then I start debugging (F9) 3. Then, at the first breakpoint, I press F8 (Step Over). This makes this dialog appear: When I look in the project folder, the only file which has been changed since debug start is MyProject.res. So why this file gets changed after the start of the debug session? This is the content of the RES file: This is very annoying and did not happen in previous Delphi versions. How can this be avoided?
  2. Dalija Prasnikar

    New Inline variables mess up IDE

    Not really... Main problem with IDE is that it uses different parser... so when compiler changes and gets new features IDE part also needs to be updated with support for new features. That is what is missing here. IDE does not know about inline variables. According to May 2019 roadmap https://community.idera.com/developer-tools/b/blog/posts/may-2019-rad-studio-roadmap-commentary-from-product-management this problem will be solved by using LSP (Language Server Protocol) https://langserver.org/ That way, there will no longer be discrepancy between IDE and compiler.
  3. uligerhardt

    Funny Code in System.Types

    I wasn't clear enough... Why would you rely on this even if it worked?
  4. Edwin Yip

    Marshmellow

    At least it's better than non-existence.
  5. It always depends on particular situation. Both composition and inheritance have their place. Sometimes you can use either, sometimes there is a clear distinction. Some tips that can help you decide. IS-A - inheritance - Sword IS-A Weapon so Sword should inherit Weapon HAS-A - composition or aggregation - Unit HAS-A Weapon so Unit can be composed with Weapon object With simple classes that satisfy IS-A condition plain inheritance will do. With more complex classes, you may want to use composition or delegate some behavior to other classes, especially if that behavior can be reused independently. Delegation - delegate behavior to another class when it is not an objects responsibility to implement behavior on its own Composition - when object is gone the composed objects are also gone - when Pizza is gone so are the ingredients Aggregation - class is used as a part of another class, but still exists outside that other class - when Unit dies Weapon still exists
×