Lely core libraries 2.3.4
|
This file is part of the CANopen library; it contains the implementation of the CANopen type functions. More...
#include "co.h"
#include <lely/co/type.h>
#include <lely/co/def/basic.def>
#include <lely/co/def/type.def>
Go to the source code of this file.
Functions | |
int | co_type_is_basic (co_unsigned16_t type) |
Returns 1 if the specified (static) data type is a basic type, and 0 if not. | |
int | co_type_is_array (co_unsigned16_t type) |
Returns 1 if the specified (static) data type is an array, and 0 if not. | |
size_t | co_type_sizeof (co_unsigned16_t type) |
Returns the native size (in bytes) of a value of the specified data type, or 1 if it is not a static data type. | |
size_t | co_type_alignof (co_unsigned16_t type) |
Returns the alignment requirements (in bytes) of a value of the specified data type, or 1 if it is not a static data type. | |
This file is part of the CANopen library; it contains the implementation of the CANopen type functions.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Definition in file type.c.
size_t co_type_sizeof | ( | co_unsigned16_t | type | ) |
Returns the native size (in bytes) of a value of the specified data type, or 1 if it is not a static data type.
In case of strings or domains, this function returns the size of a pointer.
size_t co_type_alignof | ( | co_unsigned16_t | type | ) |
Returns the alignment requirements (in bytes) of a value of the specified data type, or 1 if it is not a static data type.
In case of strings or domains, this function returns the alignment requirements of a pointer.