<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Применение директивы #error</title>
		<description>Discuss Применение директивы #error</description>
		<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html</link>
		<lastBuildDate>Tue, 21 Apr 2026 03:43:03 +0000</lastBuildDate>
		<generator>JComments</generator>
		<atom:link href="https://chipenable.ru/index.php/component/jcomments/feed/com_k2/72.html" rel="self" type="application/rss+xml" />
		<item>
			<title>Pashgan says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1367</link>
			<description><![CDATA[Да это стеб.]]></description>
			<dc:creator>Pashgan</dc:creator>
			<pubDate>Tue, 15 Mar 2011 19:51:38 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1367</guid>
		</item>
		<item>
			<title>Pashgan says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1365</link>
			<description><![CDATA[Да.. опечатался.]]></description>
			<dc:creator>Pashgan</dc:creator>
			<pubDate>Tue, 15 Mar 2011 19:48:22 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1365</guid>
		</item>
		<item>
			<title>Zebra says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1350</link>
			<description><![CDATA[Регулярно пользуюсь #error. Однако тот же Nigel Jones в тесте 0x10 вопросов, указал что им пользуются только ботаны.]]></description>
			<dc:creator>Zebra</dc:creator>
			<pubDate>Sat, 12 Mar 2011 08:56:21 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1350</guid>
		</item>
		<item>
			<title>Den says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1248</link>
			<description><![CDATA[>>#if (INT_MAX != 33767) А разве не 32767?]]></description>
			<dc:creator>Den</dc:creator>
			<pubDate>Fri, 25 Feb 2011 10:30:04 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1248</guid>
		</item>
		<item>
			<title>Глазастер says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1234</link>
			<description><![CDATA[Да ! поддерживает хороший стиль и систематизирует код (мой точно !) :lol:]]></description>
			<dc:creator>Глазастер</dc:creator>
			<pubDate>Thu, 24 Feb 2011 20:33:17 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-1234</guid>
		</item>
		<item>
			<title>Neiver says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-829</link>
			<description><![CDATA[Всем-бы хороша директива #error, но вот только работает она в купе с конструкцией #if/#endif. Что существенно ограничивает ее область применения проверкой констант препроцессора. Для проверки константных вырыжений язака Си(не препроцессора) она не подходит. Например такая конструкция не сработает:
stru ct A{
int a, b, c;
...
//много всего
};
#if sizeof(A) > EEPROM_SIZE
#er ror struct A does not feet into EEPROM
#endif Препроцессор ничего не знает о sizeof и о размере структур. Я в таких случаях пользуюсь StaticAssert. Простейшая реализация на Си выглядит так:
#define CONCAT2(First, Second) (First ## Second)
#define CONCAT(First, Second) CONCAT2(First, Second)
#define STATIC_ASSERT(e xpr) typedef char CONCAT(static_a ssert_failed_at _line_, __LINE__) [(expr) ? 1 : -1] Пользоваться им так:
STATIC_ASS ERT(s izeof(A) ]]></description>
			<dc:creator>Neiver</dc:creator>
			<pubDate>Tue, 30 Nov 2010 13:53:36 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-829</guid>
		</item>
		<item>
			<title>Pashgan says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-816</link>
			<description><![CDATA[да пожалуйста]]></description>
			<dc:creator>Pashgan</dc:creator>
			<pubDate>Tue, 23 Nov 2010 21:55:03 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-816</guid>
		</item>
		<item>
			<title>foxit says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-813</link>
			<description><![CDATA[Спасибо за статью]]></description>
			<dc:creator>foxit</dc:creator>
			<pubDate>Tue, 23 Nov 2010 07:01:34 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-813</guid>
		</item>
		<item>
			<title>brawaga says:</title>
			<link>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-811</link>
			<description><![CDATA[Воистину.]]></description>
			<dc:creator>brawaga</dc:creator>
			<pubDate>Mon, 22 Nov 2010 04:44:33 +0000</pubDate>
			<guid>https://chipenable.ru/index.php/programming-avr/item/72-primenenie-direktivy-#error.html#comment-811</guid>
		</item>
	</channel>
</rss>
