anchor.diff:     THEN
   ;
   
  +: partition>part-entry ( partition -- part-entry )
  +   1- /partition-entry * block mbr>partition-table +
  +;
  +
  +: partition>start-sector ( partition -- sector-offset )
  +   partition>part-entry part-entry>sector-offset l@-le
  +;
   
   \ This word returns true if the currently loaded block has _NO_ MBR magic
   : no-mbr? ( -- true|false )
  -   0 read-sector block mbr>magic w@-le aa55 <>
  +   0 read-sector
  +   1 partition>part-entry part-entry>id c@ ee = IF TRUE EXIT THEN \ GPT partition found
  +   block mbr>magic w@-le aa55 <>
  +;
  +
  +\ This word returns true if the currently loaded block has _NO_ GPT partition id
  +: no-gpt? ( -- true|false )
  +   0 read-sector
  +   1 partition>part-entry part-entry>id c@ ee <>
   ;
   
   : pc-extended-partition? ( part-entry-addr -- true|false )
  
positive.code: 0 INSTANCE VALUE args
  0 INSTANCE VALUE args-len
  
  
  INSTANCE VARIABLE block#  \ variable to store logical sector#
  INSTANCE VARIABLE hit#    \ partition counter
  
negative.code: 
  CONSTANT /partition-entry
  
  STRUCT
          8 field gpt>signature
          4 field gpt>revision
          4 field gpt>header-size
          4 field gpt>header-crc32
          4 field gpt>reserved
          8 field gpt>current-lba
          8 field gpt>backup-lba
          8 field gpt>first-lba
          8 field gpt>last-lba
         10 field gpt>disk-guid
          8 field gpt>part-entry-lba
          4 field gpt>num-part-entry
          4 field gpt>part-entry-size
          4 field gpt>part-array-crc32
        1a4 field gpt>reserved
  
  CONSTANT /gpt-header
  
  STRUCT
         10 field gpt-part-entry>part-type-guid
         10 field gpt-part-entry>part-guid
          8 field gpt-part-entry>first-lba
          8 field gpt-part-entry>last-lba
          8 field gpt-part-entry>attribute
         48 field gpt-part-entry>part-name
  
  CONSTANT /gpt-part-entry
  
  \ Defined by IEEE 1275-1994 (3.8.1)
  
  