2026/08/12

From WoozleCodes
Jump to navigation Jump to search
Wednesday, August 12, 2026 (#224)
prev ⇐ Tuesday Wednesday Thursday

References

Main Work

  • Ferreteria FileSys stuff in order to support sftp in FTM
    • Refactoring clades used by DBA which got broken by those changes

So, here's a weird one:

Cannot make non static method Woozalia\Ferret\Data\Mem\iQVar::TypeOk() static in class Woozalia\Ferret\Sys\Data\r1\Value\cObj 

First off, class B has *no relation* to class A, as far as I can tell. Continuing the weirdness, class B descends from another class (C) which *also* defines TypeOk() as a static function -- but no error *there*.

In trying to figure out why PHP thinks class B needs to inherit stuff from class A, I changed B::TypeOk() to dynamic -- resulting in:

Cannot make static method Woozalia\Ferret\Sys\Data\r1\cValue::TypeOk() non static in class Woozalia\Ferret\Sys\Data\r1\Value\cObj

The first class mentioned there is class C -- so *that* error at least makes sense.... but if B violates the rule, C violates it too and is above B in the chain-of-inheritance, so *it* should be causing the error.

I think this must be another case of PHP getting confused about what the problem actually is. There's probably an error, but not the one described.

  • 09:09 I temporarily removed B::TypeOk(), and now the error shows up in C::TypeOk() (B's parent). Okay. So I guess it checks the requested class first, and then goes on to the parents.
  • 10:16 It looks like the problem was actually in a descendant class (not mentioned in the error message) which was bringing in A's interface.