VTK
vtkWrappingHints.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkWrappingHints.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
23 #ifndef vtkWrappingHints_h
24 #define vtkWrappingHints_h
25 
26 #ifdef __VTK_WRAP__
27 #define VTK_WRAP_HINTS_DEFINED
28 // The return value points to a newly-created VTK object.
29 #define VTK_NEWINSTANCE [[vtk::newinstance]]
30 // The parameter is a pointer to a zerocopy buffer.
31 #define VTK_ZEROCOPY [[vtk::zerocopy]]
32 // Set preconditions for a function
33 #define VTK_EXPECTS(x) [[vtk::expects(x)]]
34 // Set size hint for parameter or return value
35 #define VTK_SIZEHINT(...) [[vtk::sizehint(__VA_ARGS__)]]
36 #endif
37 
38 #ifndef VTK_WRAP_HINTS_DEFINED
39 #define VTK_NEWINSTANCE
40 #define VTK_ZEROCOPY
41 #define VTK_EXPECTS(x)
42 #define VTK_SIZEHINT(...)
43 #endif
44 
45 #endif
46 // VTK-HeaderTest-Exclude: vtkWrappingHints.h