File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed 
sycl/doc/extensions/proposed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 100100---- 
101101class device { 
102102  // ... 
103-   int  ext_oneapi_to_index() const; 
104-   static device ext_oneapi_from_index(int  index); 
103+   size_t  ext_oneapi_to_index() const; 
104+   static device ext_oneapi_from_index(size_t  index); 
105105}; 
106106---- 
107107|====
@@ -113,7 +113,7 @@ class device {
113113a@
114114[source,c++]
115115---- 
116- int  ext_oneapi_to_index() const;
116+ size_t  ext_oneapi_to_index() const;
117117---- 
118118|====
119119
@@ -131,7 +131,7 @@ not a root device.
131131a@
132132[source,c++]
133133---- 
134- static device ext_oneapi_from_index(int  index); 
134+ static device ext_oneapi_from_index(size_t  index); 
135135---- 
136136|====
137137
@@ -155,7 +155,7 @@ int main() {
155155  sycl::device d1;  // Get the default device. 
156156                    // There is no guarantee this has index 0. 
157157
158-   int  index = d1.ext_oneapi_to_index(); 
158+   size_t  index = d1.ext_oneapi_to_index(); 
159159  sycl::device d2 = sycl::device::ext_oneapi_from_index(index); 
160160  assert(d1 == d2); 
161161} 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments