Nп/п : 29 из 100
 От   : reinert                             2:5075/128        21 сен 23 23:25:39
 К    : All                                                   21 сен 23 09:28:02
 Тема : What I do wrong here?
----------------------------------------------------------------------------------
                                                                                 
@MSGID:
<837cb29b-77c2-4410-bbbb-05c38051aa6fn@googlegroups.com> 2edf4d92
@REPLYADDR reinert <reinkor@gmail.com>
@REPLYTO 2:5075/128 reinert
@CHRS: CP866 2
@RFC: 1 0
@RFC-Message-ID:
<837cb29b-77c2-4410-bbbb-05c38051aa6fn@googlegroups.com>
@TZUTC: -0700
@PID: G2/1.0
@TID: FIDOGATE-5.12-ge4e8b94
-- Assume the following ordered_map:

     package n_cells1_p is new ada.containers.ordered_maps
           (key_type => celltype1_t, element_type => Natural);
      use n_cells1_p;
      n_cells1 : n_cells1_p.map;

 -- This statemanet is OK according to latest gnat (latest alire release):
        n_cells1(cells1(e.id).type1) := n_cells1(cells1(e.id).type1) + 1;

-- But the compiler does not like this:
        n_cells1(cells1(e.id).type1) := @ + 1;

(giving messages: 
error: expected type universal integer 
error: found private type "Ada.Containers.Ordered_Maps.Reference_Type" ...

OK, I can live with the first alternative, but I would like to know...

reinert

--- G2/1.0
 * Origin: usenet.network (2:5075/128)
SEEN-BY: 5001/100 5005/49 5015/255 5019/40 5020/715
848 1042 4441 12000
SEEN-BY: 5030/49 1081 5058/104 5075/128
@PATH: 5075/128 5020/1042 4441



   GoldED+ VK   │                                                 │   09:55:30    
                                                                                
В этой области больше нет сообщений.

Остаться здесь
Перейти к списку сообщений
Перейти к списку эх